summaryrefslogtreecommitdiffstatshomepage
path: root/src/osd/windows/drawd3d.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/osd/windows/drawd3d.c')
-rw-r--r--src/osd/windows/drawd3d.c28
1 files changed, 8 insertions, 20 deletions
diff --git a/src/osd/windows/drawd3d.c b/src/osd/windows/drawd3d.c
index f260b3f0758..4d40c31f587 100644
--- a/src/osd/windows/drawd3d.c
+++ b/src/osd/windows/drawd3d.c
@@ -44,18 +44,6 @@
#include "drawd3d.h"
-// Visual Studio 2013 is the first version that supports roundf
-#if defined(_MSC_VER) && (_MSC_VER < 1800)
-
-float roundf(float f)
-{
- if (f < 0)
- return ceil(f - 0.5);
-
- return floor(f + 0.5);
-}
-
-#endif
//============================================================
// DEBUGGING
@@ -1702,14 +1690,14 @@ void renderer::draw_quad(const render_primitive *prim)
return;
// fill in the vertexes clockwise
- vertex[0].x = roundf(prim->bounds.x0) - 0.5f;
- vertex[0].y = roundf(prim->bounds.y0) - 0.5f;
- vertex[1].x = roundf(prim->bounds.x1) - 0.5f;
- vertex[1].y = roundf(prim->bounds.y0) - 0.5f;
- vertex[2].x = roundf(prim->bounds.x0) - 0.5f;
- vertex[2].y = roundf(prim->bounds.y1) - 0.5f;
- vertex[3].x = roundf(prim->bounds.x1) - 0.5f;
- vertex[3].y = roundf(prim->bounds.y1) - 0.5f;
+ vertex[0].x = prim->bounds.x0 - 0.5f;
+ vertex[0].y = prim->bounds.y0 - 0.5f;
+ vertex[1].x = prim->bounds.x1 - 0.5f;
+ vertex[1].y = prim->bounds.y0 - 0.5f;
+ vertex[2].x = prim->bounds.x0 - 0.5f;
+ vertex[2].y = prim->bounds.y1 - 0.5f;
+ vertex[3].x = prim->bounds.x1 - 0.5f;
+ vertex[3].y = prim->bounds.y1 - 0.5f;
float width = prim->bounds.x1 - prim->bounds.x0;
float height = prim->bounds.y1 - prim->bounds.y0;