mirror of
https://github.com/bkaradzic/bgfx.git
synced 2026-02-17 20:52:36 +01:00
Cleanup.
This commit is contained in:
committed by
Branimir Karadžić
parent
913dd0224d
commit
105fd8cdf1
@@ -381,8 +381,10 @@ public:
|
||||
}
|
||||
|
||||
// Start a new readback?
|
||||
if (!m_reading
|
||||
&& m_mouseState.m_buttons[entry::MouseButton::Left])
|
||||
if (!ImGui::MouseOverArea()
|
||||
&& !m_reading
|
||||
&& m_mouseState.m_buttons[entry::MouseButton::Left]
|
||||
)
|
||||
{
|
||||
// Blit and read
|
||||
bgfx::blit(RENDER_PASS_BLIT, m_blitTex, 0, 0, m_pickingRT);
|
||||
|
||||
@@ -395,16 +395,30 @@ public:
|
||||
m_texChainFb[ii] = bgfx::createFrameBuffer(
|
||||
(uint16_t)(m_width >> ii)
|
||||
, (uint16_t)(m_height >> ii)
|
||||
, bgfx::TextureFormat::RGBA32F
|
||||
, bgfx::TextureFormat::RGBA16F
|
||||
, tsFlags
|
||||
);
|
||||
}
|
||||
|
||||
bgfx::TextureHandle gbufferTex[] =
|
||||
{
|
||||
bgfx::createTexture2D(uint16_t(m_width), uint16_t(m_height), false, 1, bgfx::TextureFormat::RGBA32F, tsFlags),
|
||||
bgfx::createTexture2D(
|
||||
uint16_t(m_width)
|
||||
, uint16_t(m_height)
|
||||
, false
|
||||
, 1
|
||||
, bgfx::TextureFormat::RGBA16F
|
||||
, tsFlags
|
||||
),
|
||||
bgfx::getTexture(m_texChainFb[0]),
|
||||
bgfx::createTexture2D(uint16_t(m_width), uint16_t(m_height), false, 1, bgfx::TextureFormat::D32F, tsFlags),
|
||||
bgfx::createTexture2D(
|
||||
uint16_t(m_width)
|
||||
, uint16_t(m_height)
|
||||
, false
|
||||
, 1
|
||||
, bgfx::TextureFormat::D32F
|
||||
, tsFlags
|
||||
),
|
||||
};
|
||||
|
||||
m_gbuffer = bgfx::createFrameBuffer(BX_COUNTOF(gbufferTex), gbufferTex, true);
|
||||
|
||||
Reference in New Issue
Block a user