Skip to content

Commit

Permalink
[fix] initialising logs and shader issue
Browse files Browse the repository at this point in the history
  • Loading branch information
MrsRina committed Mar 23, 2024
1 parent 003cc3a commit 8d98c0c
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 2 deletions.
Binary file modified lib/windows/libekg.a
Binary file not shown.
1 change: 1 addition & 0 deletions src/ekg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ void ekg::init(
ekg::log() << "Initialising EKG";

ekg::core = p_ekg_runtime;
ekg::core->f_renderer_small.font_path = p_ekg_runtime_property->p_font_path;
ekg::core->f_renderer_normal.font_path = p_ekg_runtime_property->p_font_path;
ekg::core->f_renderer_big.font_path = p_ekg_runtime_property->p_font_path;
ekg::core->init();
Expand Down
5 changes: 3 additions & 2 deletions src/os/ekg_opengl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,9 @@ void ekg::os::opengl::init() {
" }\n"

" if (uActiveTexture && !shouldDiscard) {"
" vec4 color = vFragColor;\n"
" vFragColor = texture(uTextureSampler, vTexCoord);\n"
" vFragColor = vec4(vFragColor.xyz - ((1.0f - uColor.xyz) - 1.0f), vFragColor.w - (1.0f - uColor.w));\n"
" vFragColor = vec4(vFragColor.xyz - ((1.0f - color.xyz) - 1.0f), vFragColor.w - (1.0f - color.w));\n"
" }\n"
"}"
};
Expand Down Expand Up @@ -168,7 +169,7 @@ void ekg::os::opengl::init() {
this->uniform_viewport_height = glGetUniformLocation(this->pipeline_program, "uViewportHeight");
this->uniform_projection = glGetUniformLocation(this->pipeline_program, "uProjection");

ekg::log() << "GPU allocator initialised";
ekg::log() << "GPU shaders, pipeline program, and uniforms done";
}

void ekg::os::opengl::quit() {
Expand Down
Binary file modified test/build/windows/ekg-gui-showcase-test.exe
Binary file not shown.

0 comments on commit 8d98c0c

Please sign in to comment.