diff options
| author | Lioncash <mathew1800@gmail.com> | 2018-05-10 19:06:19 -0400 |
|---|---|---|
| committer | Lioncash <mathew1800@gmail.com> | 2018-05-10 19:42:20 -0400 |
| commit | ba01f6dba3cf1858ed64bc7f1abee744ffd313ec (patch) | |
| tree | 277ae9faa7dabc173cbe2d2c9b77db850d5c682e /Source/Core/VideoBackends/OGL | |
| parent | 3cca05185029ae4572529bf986675c772cc0ac5a (diff) | |
CommonFuncs: Convert ROUND_UP_POW2 macro to a function
Also move it to MathUtils where it belongs with the rest of the
power-of-two functions. This gets rid of pollution of the current scope
of any translation unit with b<value> macros that aren't intended to be
used directly.
Diffstat (limited to 'Source/Core/VideoBackends/OGL')
| -rw-r--r-- | Source/Core/VideoBackends/OGL/StreamBuffer.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Source/Core/VideoBackends/OGL/StreamBuffer.cpp b/Source/Core/VideoBackends/OGL/StreamBuffer.cpp index 1307350086..e32afd9a47 100644 --- a/Source/Core/VideoBackends/OGL/StreamBuffer.cpp +++ b/Source/Core/VideoBackends/OGL/StreamBuffer.cpp @@ -5,8 +5,8 @@ #include "VideoBackends/OGL/StreamBuffer.h" #include "Common/Align.h" -#include "Common/CommonFuncs.h" #include "Common/GL/GLUtil.h" +#include "Common/MathUtil.h" #include "Common/MemoryUtil.h" #include "VideoBackends/OGL/Render.h" @@ -25,8 +25,8 @@ static u32 GenBuffer() } StreamBuffer::StreamBuffer(u32 type, u32 size) - : m_buffer(GenBuffer()), m_buffertype(type), m_size(ROUND_UP_POW2(size)), - m_bit_per_slot(IntLog2(ROUND_UP_POW2(size) / SYNC_POINTS)) + : m_buffer(GenBuffer()), m_buffertype(type), m_size(MathUtil::NextPowerOf2(size)), + m_bit_per_slot(IntLog2(MathUtil::NextPowerOf2(size) / SYNC_POINTS)) { m_iterator = 0; m_used_iterator = 0; |
