¡ cgContext =
CgGL.cgCreateContext();
¡
¡ cgVertexProfile =
CgGL.CG_PROFILE_VP20;
¡
¡ CgGL.cgGLEnableProfile(
cgVertexProfile);
¡
¡
cgVertexProgram =
CgGL.cgCreateProgramFromFile( cgContext, CgGL.CG_SOURCE, "Normal.cg", cgVertexProfile,
"Normal", null);
¡
¡
CgGL.cgGLLoadProgram(cgVertexProgram);
¡
¡
cgModelViewProjMatrix = CgGL.cgGetNamedParameter( cgVertexProgram,
"ModelViewProjMatrix");
¡