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:
authorJean-Luc Peurière <jlp@nerim.net>2008-02-18 19:31:25 +0300
committerJean-Luc Peurière <jlp@nerim.net>2008-02-18 19:31:25 +0300
commit09bb791249da886521759ead88b9b36673f6968f (patch)
treee28e28a73adb190118cc0668101d3b47427feddd /source/blender
parent5e97b48fceb60d5b04adea457fc95138cf12d454 (diff)
making the new transform methods work on Os X
getndof return a 7 floats array, but only the first 6 are axis the last one is a delta and seems to be much smaller on windows systems this value should be ignored for the moment
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/src/editscreen.c4
-rwxr-xr-xsource/blender/src/transform.c4
-rw-r--r--source/blender/src/transform_ndofinput.c6
3 files changed, 7 insertions, 7 deletions
diff --git a/source/blender/src/editscreen.c b/source/blender/src/editscreen.c
index 15c3d8c6fec..541790ec98e 100644
--- a/source/blender/src/editscreen.c
+++ b/source/blender/src/editscreen.c
@@ -2174,10 +2174,10 @@ void filterNDOFvalues(float *sbval)
int i=0;
float max = 0.0;
- for (i =0; i<5;i++)
+ for (i =0; i<6;i++)
if (fabs(sbval[i]) > max)
max = fabs(sbval[i]);
- for (i =0; i<5;i++)
+ for (i =0; i<6;i++)
if (fabs(sbval[i]) != max )
sbval[i]=0.0;
}
diff --git a/source/blender/src/transform.c b/source/blender/src/transform.c
index 0d5868d9032..84ad5a91551 100755
--- a/source/blender/src/transform.c
+++ b/source/blender/src/transform.c
@@ -3273,7 +3273,7 @@ void NDofTransform()
getndof(fval);
- for(i = 0; i < 7; i++)
+ for(i = 0; i < 6; i++)
{
float val = fabs(fval[i]);
if (val > maxval)
@@ -3301,7 +3301,7 @@ void NDofTransform()
mode = TFM_TRACKBALL;
break;
default:
- printf("ndof transform mode not impremented yet");
+ printf("ndof: what we are doing here ?");
}
if (mode != 0)
diff --git a/source/blender/src/transform_ndofinput.c b/source/blender/src/transform_ndofinput.c
index 34ab8b95e7b..0de4b026b52 100644
--- a/source/blender/src/transform_ndofinput.c
+++ b/source/blender/src/transform_ndofinput.c
@@ -62,7 +62,7 @@ void initNDofInput(NDofInput *n)
void resetNDofInput(NDofInput *n)
{
int i;
- for(i = 0; i < 7; i++)
+ for(i = 0; i < 6; i++)
{
n->fval[i] = 0.0f;
}
@@ -113,7 +113,7 @@ void applyNDofInput(NDofInput *n, float *vec)
{
int i, j;
- for (i = 0, j = 0; i < 7; i++)
+ for (i = 0, j = 0; i < 6; i++)
{
if (n->axis & (1 << i))
{
@@ -136,7 +136,7 @@ int updateNDofMotion(NDofInput *n)
if (G.vd->ndoffilter)
filterNDOFvalues(fval);
- for(i = 0; i < 7; i++)
+ for(i = 0; i < 6; i++)
{
if (!retval && fval[i] != 0.0f)
{