@@ -106,21 +106,15 @@ Renderer::Renderer(int width, int height, int gx, int gy, int texsize, BeatDetec
106106 }
107107 }
108108
109-
110- #ifdef USE_CG
111109 shaderEngine.setParams (renderTarget->texsize , renderTarget->textureID [1 ], aspect, beatDetect, textureManager);
112- #endif
113-
114110}
115111
116112void Renderer::SetPipeline (Pipeline &pipeline)
117113{
118114 currentPipe = &pipeline;
119- #ifdef USE_CG
120115 shaderEngine.reset ();
121116 shaderEngine.loadShader (pipeline.warpShader );
122117 shaderEngine.loadShader (pipeline.compositeShader );
123- #endif
124118}
125119
126120void Renderer::ResetTextures ()
@@ -162,9 +156,7 @@ void Renderer::SetupPass1(const Pipeline &pipeline, const PipelineContext &pipel
162156#endif
163157 glLoadIdentity ();
164158
165- #ifdef USE_CG
166159 shaderEngine.RenderBlurTextures (pipeline, pipelineContext, renderTarget->texsize );
167- #endif
168160}
169161
170162void Renderer::RenderItems (const Pipeline &pipeline, const PipelineContext &pipelineContext)
@@ -274,13 +266,9 @@ void Renderer::RenderFrame(const Pipeline &pipeline, const PipelineContext &pipe
274266
275267 SetupPass1 (pipeline, pipelineContext);
276268
277- #ifdef USE_CG
278- shaderEngine.enableShader (currentPipe->warpShader , pipeline, pipelineContext);
279- #endif
269+ // shaderEngine.enableShader(currentPipe->warpShader, pipeline, pipelineContext);
280270 Interpolation (pipeline);
281- #ifdef USE_CG
282- shaderEngine.disableShader ();
283- #endif
271+ // shaderEngine.disableShader();
284272
285273 RenderItems (pipeline, pipelineContext);
286274 FinishPass1 ();
@@ -430,9 +418,7 @@ void Renderer::reset(int w, int h)
430418 this -> vw = w;
431419 this -> vh = h;
432420
433- #if USE_CG
434421 shaderEngine.setAspect (aspect);
435- #endif
436422
437423#ifndef EMSCRIPTEN
438424 glShadeModel (GL_SMOOTH);
@@ -715,8 +701,8 @@ void Renderer::draw_stats()
715701 glRasterPos2f (0 , -.25 + offset);
716702 sprintf (buffer, " textures: %.1fkB" , textureManager->getTextureMemorySize () / 1000 .0f );
717703 other_font->Render (buffer);
718- # ifdef USE_CG
719- glRasterPos2f (0 , -.29 + offset);
704+
705+ glRasterPos2f (0 , -.29 + offset);
720706 sprintf (buffer, " shader profile: %s" , shaderEngine.profileName .c_str ());
721707 other_font->Render (buffer);
722708
@@ -727,8 +713,8 @@ void Renderer::draw_stats()
727713 glRasterPos2f (0 , -.37 + offset);
728714 sprintf (buffer, " comp shader: %s" , currentPipe->compositeShader .enabled ? " on" : " off" );
729715 other_font->Render (buffer);
730- # endif
731- glPopMatrix ();
716+
717+ glPopMatrix ();
732718 // glBlendFunc(GL_SRC_ALPHA,GL_ONE_MINUS_SRC_ALPHA);
733719
734720
@@ -769,9 +755,7 @@ void Renderer::CompositeOutput(const Pipeline &pipeline, const PipelineContext &
769755
770756 glEnable (GL_TEXTURE_2D);
771757
772- #ifdef USE_CG
773- shaderEngine.enableShader (currentPipe->compositeShader , pipeline, pipelineContext);
774- #endif
758+ // shaderEngine.enableShader(currentPipe->compositeShader, pipeline, pipelineContext);
775759
776760 float tex[4 ][2 ] =
777761 {
@@ -801,9 +785,7 @@ void Renderer::CompositeOutput(const Pipeline &pipeline, const PipelineContext &
801785
802786 glDisableClientState (GL_TEXTURE_COORD_ARRAY);
803787
804- #ifdef USE_CG
805- shaderEngine.disableShader ();
806- #endif
788+ // shaderEngine.disableShader();
807789
808790 for (std::vector<RenderItem*>::const_iterator pos = pipeline.compositeDrawables .begin (); pos
809791 != pipeline.compositeDrawables .end (); ++pos)
0 commit comments