Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTon Roosendaal <ton@blender.org>2008-09-20 17:02:06 +0400
committerTon Roosendaal <ton@blender.org>2008-09-20 17:02:06 +0400
commit2bd6e1ae82bf2a8fb7a2044b4e032b67cfec861d (patch)
tree37f0f04900808f7cb315e54659a41de8494288da /source/blender/gpu
parent63f10e6b550796307ccc22099efa9a7326290604 (diff)
Patch #8461, by Rob Hausauer
This unifies all usage of FTOCHAR, putting it in utildefines.h Submitter did several interesting tests for speed, check it here: http://projects.blender.org/tracker/?func=detail&atid=127&aid=8461&group_id=9
Diffstat (limited to 'source/blender/gpu')
-rw-r--r--source/blender/gpu/intern/gpu_extensions.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/gpu/intern/gpu_extensions.c b/source/blender/gpu/intern/gpu_extensions.c
index 10603aa7283..a8dc369460c 100644
--- a/source/blender/gpu/intern/gpu_extensions.c
+++ b/source/blender/gpu/intern/gpu_extensions.c
@@ -40,6 +40,7 @@
#include "BKE_image.h"
#include "BKE_global.h"
+#include "BKE_utildefines.h"
#include "IMB_imbuf.h"
#include "IMB_imbuf_types.h"
@@ -154,7 +155,6 @@ struct GPUTexture {
int depth; /* is a depth texture? */
};
-#define FTOCHAR(val) val<=0.0f?0: (val>=1.0f?255: (char)(255.0f*val))
static unsigned char *GPU_texture_convert_pixels(int length, float *fpixels)
{
unsigned char *pixels, *p;