36 std::string
lookup_and_register_asset_dir(
const char* exe_path,
const char* asset_file=
"fonts/freefont/FreeSansBold.ttf",
const char* asset_install_subdir=
"gamp")
noexcept;
38 std::string
resolve_asset(
const std::string &asset_file,
bool lookup_direct=
false)
noexcept;
123 class GampEnv : public
jau::root_environment {
134 const
bool exploding;
170 static GampEnv&
get() noexcept {
const bool DEBUG_WT_EVENT
Debug all WT event communication.
static GampEnv & get() noexcept
const bool DEBUG_RENDER_GL_GLSL_CODE
Debug shader code, i.e.
const bool DEBUG_GLOBAL
Global Debug flag, retrieved first to triggers GampEnv initialization.
const bool DEBUG_GRAPH_RENDER
Debug Graph Renderer.
const bool DEBUG_RENDER_GL_GLSL_STATE
Debug shader state, i.e.
int expected_fps() noexcept
Returns expected fps, either gpu_forced_fps() if set, otherwise monitor_fps().
std::string lookup_and_register_asset_dir(const char *exe_path, const char *asset_file="fonts/freefont/FreeSansBold.ttf", const char *asset_install_subdir="gamp") noexcept
const jau::fraction_timespec & gpu_avg_framedur() noexcept
Returns the measured gpu frame duration in [s] each 5s, starting with 1/gpu_avg_fps()
void mainloop_void() noexcept
Calls mainloop_default(), but exits application if returning false.
jau::fraction_timespec getElapsedMonotonicTime() noexcept
Returns the elapsed monotonic time since init_gfx_subsystem, synchronized with the gfx subsystem time...
bool init_gfx_subsystem(const char *exe_path)
GFX Toolkit: Initialize the subsystem once.
std::string resolve_asset(const std::string &asset_file, bool lookup_direct=false) noexcept
float gpu_avg_fps() noexcept
Returns the measured gpu fps each 5s, starting with monitor_fps()
bool is_gfx_subsystem_initialized() noexcept
jau::fraction_timespec expected_framedur() noexcept
Returns the expected frame duration in [s], i.e.
bool mainloop_default() noexcept
Performs the whole tasks for all created gamp::wt::Window instances.
int gpu_forced_fps() noexcept
Returns optional forced frames per seconds or -1 if unset, set via set_gpu_forced_fps().
size_t handle_events() noexcept
GFX Toolkit: Handle windowing and keyboard events.
void swap_gpu_buffer(int fps) noexcept
GFX Toolkit: Swap GPU back to front framebuffer of all windows using given fps, maintaining vertical ...
int monitor_fps() noexcept
Monitor frames per seconds.
void set_gpu_forced_fps(int fps) noexcept
Optional forced frames per seconds, pass to swap_gpu_buffer() by default.
std::string asset_dir() noexcept
Gamp: Graphics, Audio, Multimedia and Processing Framework (Native C++, WebAssembly,...
__pack(...): Produces MSVC, clang and gcc compatible lead-in and -out macros.
Timespec structure using int64_t for its components in analogy to struct timespec_t on 64-bit platfor...