}
case AT_PrintBounds:
{
- printf("%s\t%s\t%s\t%s\n", Str(view->GetBounds().x).c_str(), Str(view->GetBounds().y).c_str(), Str(view->GetBounds().w).c_str(), Str(view->GetBounds().h).c_str());
+ printf("%s\t%s\t%s\t%s\t%s\t%s\n", Str(view->GetBounds().x).c_str(), Str(view->GetBounds().y).c_str(), Str(view->GetBounds().w).c_str(), Str(view->GetBounds().h).c_str(), Str(Log10(view->GetBounds().w)).c_str(), Str(Log10(view->GetBounds().h)).c_str());
break;
}
+ case AT_ProfileDisplay:
+ {
+ g_profiler.Enable(currentAction.iz);
+ break;
+ }
default:
Fatal("Unknown script command in queue.");
}
AT_SetBounds,
AT_QueryGPUBounds, // query bounds of Beziers when transformed to GPU
AT_ScreenShot, // take screenshot
- AT_PrintFPS, // Print FPS statistics about the frames
+ AT_PrintSPF, // Print FPS statistics about the frames
AT_PrintBounds, // Print bounds
+ AT_ProfileDisplay,
AT_Quit
};
#endif
// We want to crash if we ever get a NaN.
-- // AH, so *this* is where that got enabled, I was looking for compiler flags
++ // Not any more
#ifndef __MINGW32__
- feenableexcept(FE_DIVBYZERO | FE_INVALID); // | FE_OVERFLOW);
- feenableexcept(FE_DIVBYZERO | FE_INVALID | FE_OVERFLOW);
++ //feenableexcept(FE_DIVBYZERO | FE_INVALID); // | FE_OVERFLOW);
#endif
#if REALTYPE == REAL_MPFRCPP
- mpfr_set_default_prec(6);
+
+ #ifdef MPFR_PRECISION
+ mpfr_set_default_prec(MPFR_PRECISION);
+ #else
+ mpfr_set_default_prec(23);
+ #endif
+
#endif
DebugRealInfo();
scr.DebugFontPrint("Doing rendering using CPU.\n");
}
#endif // 0
-
+
- scr.Present();
-
+ if (make_movie)
+ {
+ std::stringstream s;
+ s << "frame" << frames << ".bmp";
+ scr.ScreenShot(s.str().c_str());
- }
++ }
++
++
+
+ g_profiler.BeginZone("scr.Present()");
+ scr.Present();
+ g_profiler.EndZone();
+ g_profiler.EndFrame();
++
++
}
}
}
SDL_GL_SetAttribute(SDL_GL_CONTEXT_MAJOR_VERSION, 3);
- SDL_GL_SetAttribute(SDL_GL_CONTEXT_MINOR_VERSION, 1);
+ SDL_GL_SetAttribute(SDL_GL_CONTEXT_MINOR_VERSION, 3);
SDL_GL_SetAttribute(SDL_GL_CONTEXT_FLAGS, SDL_GL_CONTEXT_DEBUG_FLAG);
SDL_GL_SetAttribute(SDL_GL_CONTEXT_PROFILE_MASK, SDL_GL_CONTEXT_PROFILE_CORE);
--
++ //SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 1);
m_gl_context = SDL_GL_CreateContext(m_window);
++ //SDL_GL_SetSwapInterval(1);
ogl_LoadFunctions();
-# BECAUSE I CAN
+# Script for the turtles video
gpu
lazy
-profileon
--#debugfont off
+
- loop 1000 wait
+# Wait to start video
++# loop 1000 wait
+
+#Load first turtle...
loadsvg svg-tests/turtle.svg
loop 50 pxzoom 430 170 1
loadsvg svg-tests/turtle.svg
void View::UpdateObjBoundsVBO(unsigned first_obj, unsigned last_obj)
{
+ PROFILE_SCOPE("View::UpdateObjBoundsVBO");
if (m_query_gpu_bounds_on_next_frame != NULL)
{
- fprintf(m_query_gpu_bounds_on_next_frame,"# View: %s\t%s\t%s\t%s", Str(m_bounds.x).c_str(), Str(m_bounds.y).c_str(), Str(m_bounds.w).c_str(), Str(m_bounds.h).c_str());
+ fprintf(m_query_gpu_bounds_on_next_frame,"# View: %s\t%s\t%s\t%s\n", Str(m_bounds.x).c_str(), Str(m_bounds.y).c_str(), Str(m_bounds.w).c_str(), Str(m_bounds.h).c_str());
}
//m_objbounds_vbo.Invalidate();