diff options
author | 2015-07-12 23:28:38 +0200 | |
---|---|---|
committer | 2015-07-12 23:28:38 +0200 | |
commit | 9ce28641419f62fe8f95fca1dad6563cef0d995f (patch) | |
tree | 5c374dc0d1f940f294730cd2fde5ea9e39bc499e /src/osd/modules/render/drawd3d.c | |
parent | 6e5f7f5d943c3cacee4de7f0bdd618ee96c83557 (diff) |
Post Pass effects for Vector rendering
- added support for post pass effects for vector rendering (does not
work properly in full screen mode, yet)
- made texture_info::compute_size_subroutine() function public static
Diffstat (limited to 'src/osd/modules/render/drawd3d.c')
-rw-r--r-- | src/osd/modules/render/drawd3d.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/osd/modules/render/drawd3d.c b/src/osd/modules/render/drawd3d.c index 33c0b1aff97..39fbac323eb 100644 --- a/src/osd/modules/render/drawd3d.c +++ b/src/osd/modules/render/drawd3d.c @@ -2074,13 +2074,13 @@ error: // texture_info::compute_size_subroutine //============================================================ -void texture_info::compute_size_subroutine(int texwidth, int texheight, int* p_width, int* p_height) +void texture_info::compute_size_subroutine(texture_manager* texture_manager, int texwidth, int texheight, int* p_width, int* p_height) { int finalheight = texheight; int finalwidth = texwidth; // round width/height up to nearest power of 2 if we need to - if (!(m_texture_manager->get_texture_caps() & D3DPTEXTURECAPS_NONPOW2CONDITIONAL)) + if (!(texture_manager->get_texture_caps() & D3DPTEXTURECAPS_NONPOW2CONDITIONAL)) { // first the width if (finalwidth & (finalwidth - 1)) @@ -2104,7 +2104,7 @@ void texture_info::compute_size_subroutine(int texwidth, int texheight, int* p_w } // round up to square if we need to - if (m_texture_manager->get_texture_caps() & D3DPTEXTURECAPS_SQUAREONLY) + if (texture_manager->get_texture_caps() & D3DPTEXTURECAPS_SQUAREONLY) { if (finalwidth < finalheight) finalwidth = finalheight; @@ -2113,11 +2113,11 @@ void texture_info::compute_size_subroutine(int texwidth, int texheight, int* p_w } // adjust the aspect ratio if we need to - while (finalwidth < finalheight && finalheight / finalwidth > m_texture_manager->get_max_texture_aspect()) + while (finalwidth < finalheight && finalheight / finalwidth > texture_manager->get_max_texture_aspect()) { finalwidth *= 2; } - while (finalheight < finalwidth && finalwidth / finalheight > m_texture_manager->get_max_texture_aspect()) + while (finalheight < finalwidth && finalwidth / finalheight > texture_manager->get_max_texture_aspect()) { finalheight *= 2; } @@ -2151,7 +2151,7 @@ void texture_info::compute_size(int texwidth, int texheight) finalwidth += 2 * m_xborderpix; finalheight += 2 * m_yborderpix; - compute_size_subroutine(finalwidth, finalheight, &finalwidth, &finalheight); + texture_info::compute_size_subroutine(m_texture_manager, finalwidth, finalheight, &finalwidth, &finalheight); // if we added pixels for the border, and that just barely pushed us over, take it back if (finalwidth > m_texture_manager->get_max_texture_width() || finalheight > m_texture_manager->get_max_texture_height()) @@ -2162,7 +2162,7 @@ void texture_info::compute_size(int texwidth, int texheight) m_xborderpix = 0; m_yborderpix = 0; - compute_size_subroutine(finalwidth, finalheight, &finalwidth, &finalheight); + texture_info::compute_size_subroutine(m_texture_manager, finalwidth, finalheight, &finalwidth, &finalheight); } // if we're above the max width/height, do what? |