MCPcopy Create free account
hub / github.com/crownengine/crown / setRenderContextSize

Method setRenderContextSize

3rdparty/bgfx/src/renderer_gl.cpp:4176–4195  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4174 }
4175
4176 void setRenderContextSize(const Resolution& _resolution)
4177 {
4178 if (!m_glctx.isValid() )
4179 {
4180 m_glctx.create(_resolution);
4181 }
4182 else
4183 {
4184 destroyMsaaFbo();
4185
4186 m_glctx.resize(_resolution);
4187
4188 uint32_t msaa = (_resolution.reset & BGFX_RESET_MSAA_MASK)>>BGFX_RESET_MSAA_SHIFT;
4189 msaa = bx::uint32_min(m_maxMsaa, msaa == 0 ? 0 : 1<<msaa);
4190
4191 createMsaaFbo(_resolution.width, _resolution.height, msaa);
4192 }
4193
4194 m_flip = true;
4195 }
4196
4197 void invalidateCache()
4198 {

Callers

nothing calls this directly

Calls 3

isValidMethod · 0.45
createMethod · 0.45
resizeMethod · 0.45

Tested by

no test coverage detected