diff --git a/bloom.cc b/bloom.cc index 016fc79..0eeab43 100644 --- a/bloom.cc +++ b/bloom.cc @@ -7,8 +7,8 @@ namespace { static const std::string Name_( "BLOOOOM!" ); } -#define PSTART() T_Profiler::Profiler.start( Name_ ) -#define PEND() do { glFinish( ); T_Profiler::Profiler.end( Name_ ); } while ( 0 ) +#define PSTART() Globals::Profiler( ).start( Name_ ) +#define PEND() do { glFinish( ); Globals::Profiler( ).end( Name_ ); } while ( 0 ) T_BloomPass::T_BloomPass( diff --git a/combine.cc b/combine.cc index a24cea9..93a3747 100644 --- a/combine.cc +++ b/combine.cc @@ -8,8 +8,8 @@ namespace { static const std::string Name_( "Combine" ); } -#define PSTART() T_Profiler::Profiler.start( Name_ ) -#define PEND() do { glFinish( ); T_Profiler::Profiler.end( Name_ ); } while ( 0 ) +#define PSTART() Globals::Profiler( ).start( Name_ ) +#define PEND() do { glFinish( ); Globals::Profiler( ).end( Name_ ); } while ( 0 ) T_CombinePass::T_CombinePass( diff --git a/dof.cc b/dof.cc index 646bdc0..4b69bc9 100644 --- a/dof.cc +++ b/dof.cc @@ -7,8 +7,8 @@ namespace { static const std::string Name_( "DoF" ); } -#define PSTART() T_Profiler::Profiler.start( Name_ ) -#define PEND() do { glFinish( ); T_Profiler::Profiler.end( Name_ ); } while ( 0 ) +#define PSTART() Globals::Profiler( ).start( Name_ ) +#define PEND() do { glFinish( ); Globals::Profiler( ).end( Name_ ); } while ( 0 ) T_DoFPass::T_DoFPass( diff --git a/raymarcher.cc b/raymarcher.cc index 41c44d3..17cde60 100644 --- a/raymarcher.cc +++ b/raymarcher.cc @@ -8,8 +8,8 @@ namespace { static const std::string Name_( "Raymarcher" ); } -#define PSTART() T_Profiler::Profiler.start( Name_ ) -#define PEND() do { glFinish( ); T_Profiler::Profiler.end( Name_ ); } while ( 0 ) +#define PSTART() Globals::Profiler( ).start( Name_ ) +#define PEND() do { glFinish( ); Globals::Profiler( ).end( Name_ ); } while ( 0 ) T_Raymarcher::T_Raymarcher( @@ -30,13 +30,13 @@ T_Raymarcher::T_Raymarcher( void T_Raymarcher::render( ) { - PSTART( ); if ( !rtOutput_.activate( ) || !program_.valid( ) ) { glClearColor( 0 , 0 , 0 , 1 ); glClear( GL_COLOR_BUFFER_BIT ); - PEND( ); return; } + + PSTART( ); program_.enable( ); glClearColor( 0 , 0 , 0 , 1 );