Skip to content

Commit

Permalink
Updated gl viewport with LOG_WARNING instead of LOG_ERROR.
Browse files Browse the repository at this point in the history
  • Loading branch information
ggarra13 committed Oct 23, 2023
1 parent c84f6ca commit 002b200
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 8 deletions.
4 changes: 2 additions & 2 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
*.ttf -text
*.lib -text
*.dll -text
*.dylib -text
*.mov -text
*.mp4 -text
*.mpv -text
Expand All @@ -27,8 +28,7 @@
*.po filter=po
*.pot filter=poç

windows/win32/include/lib/** linguist-language=C
windows/win64/include/lib/** linguist-language=C
precompiled/windows/win64/include/lib/** linguist-language=C

*.bat linguist-language=bat
*.cpp linguist-language=C++
Expand Down
15 changes: 9 additions & 6 deletions mrv2/lib/mrvGL/mrvGLViewport.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -212,13 +212,14 @@ namespace mrv
{
gl.background = gl::OffscreenBuffer::create(
renderSize, offscreenBufferOptions);
CHECK_GL;
}
}
catch (const std::exception& e)
{
LOG_ERROR("Creating background: " << e.what());
gl.buffer.reset();
gl.stereoBuffer.reset();
LOG_WARNING("Creating background: " << e.what());
gl.background.reset();
valid(0);
}

try
Expand Down Expand Up @@ -253,8 +254,9 @@ namespace mrv
}
catch (const std::exception& e)
{
LOG_ERROR("Creating buffer: " << e.what());
LOG_WARNING("Creating buffer: " << e.what());
gl.buffer.reset();
valid(0);
}

if (can_do(FL_STEREO))
Expand All @@ -272,8 +274,9 @@ namespace mrv
}
catch (const std::exception& e)
{
LOG_ERROR("Creating stereo buffer: " << e.what());
LOG_WARNING("Creating stereo buffer: " << e.what());
gl.stereoBuffer.reset();
valid(0);
}
}
}
Expand Down Expand Up @@ -382,7 +385,7 @@ namespace mrv
glClear(GL_COLOR_BUFFER_BIT | GL_STENCIL_BUFFER_BIT);
CHECK_GL;

if (gl.background && !transparent && !p.presentation)
if (gl.background && gl.shader && !transparent && !p.presentation)
{
math::Matrix4x4f mvp;
mvp = _createTexturedRectangle();
Expand Down

0 comments on commit 002b200

Please sign in to comment.