mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 04:30:10 +01:00
llvmpipe: Implement round() for MSVC.
This commit is contained in:
parent
6bc1e9fd69
commit
095e66f695
1 changed files with 12 additions and 0 deletions
|
|
@ -40,6 +40,18 @@
|
|||
#include "lp_test.h"
|
||||
|
||||
|
||||
#ifdef PIPE_CC_MSVC
|
||||
static INLINE double
|
||||
round(double x)
|
||||
{
|
||||
if (x >= 0.0)
|
||||
return floor(x + 0.5);
|
||||
else
|
||||
return ceil(x - 0.5);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
void
|
||||
dump_type(FILE *fp,
|
||||
struct lp_type type)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue