VirtualBox

Ignore:
Timestamp:
Aug 27, 2013 10:29:35 AM (11 years ago)
Author:
vboxsync
Message:

wined3d: better copysignf

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/WINNT/Graphics/Wine_new/wined3d/glsl_shader.c

    r48073 r48078  
    3838#include "wined3d_private.h"
    3939
    40 #if defined(VBOX) && defined(RT_ARCH_AMD64)
    41 # define copysignf _copysignf
     40#if defined(VBOX)
     41# if defined(RT_ARCH_AMD64)
     42#  define copysignf _copysignf
     43# else
     44#  define _VBOX_FLOAT_BITVAL(_f) (*((const uint32_t*)((const void*)(&(_f)))))
     45DECLINLINE(float) copysignf(float val, float sign)
     46{
     47    return ((_VBOX_FLOAT_BITVAL(val) & 0x7fffffff) | (_VBOX_FLOAT_BITVAL(sign) & 0x80000000));
     48}
     49# endif
    4250#endif
    4351
     
    260268
    261269    d = value;
    262 #if defined(VBOX) && !defined(RT_ARCH_AMD64)
    263     if (value < 0.0f)
    264 #else
    265270    if (copysignf(1.0f, value) < 0.0f)
    266 #endif
    267271    {
    268272        d = -d;
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette