[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [47059] branches/soc-2011-tomato: svn merge ^/trunk/blender -r47047:47058
Campbell Barton
ideasman42 at gmail.com
Sun May 27 00:31:29 CEST 2012
Revision: 47059
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=47059
Author: campbellbarton
Date: 2012-05-26 22:31:28 +0000 (Sat, 26 May 2012)
Log Message:
-----------
svn merge ^/trunk/blender -r47047:47058
Revision Links:
--------------
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=47047
Modified Paths:
--------------
branches/soc-2011-tomato/intern/smoke/intern/FLUID_3D.cpp
branches/soc-2011-tomato/intern/smoke/intern/FLUID_3D_STATIC.cpp
branches/soc-2011-tomato/source/blender/blenkernel/intern/armature.c
branches/soc-2011-tomato/source/blender/blenkernel/intern/image.c
branches/soc-2011-tomato/source/blender/blenkernel/intern/shrinkwrap.c
branches/soc-2011-tomato/source/blender/blenlib/BLI_kdtree.h
branches/soc-2011-tomato/source/blender/blenlib/intern/BLI_kdtree.c
branches/soc-2011-tomato/source/blender/blenpluginapi/iff.h
branches/soc-2011-tomato/source/blender/editors/armature/BIF_generate.h
branches/soc-2011-tomato/source/blender/editors/armature/editarmature_generate.c
branches/soc-2011-tomato/source/blender/editors/include/ED_object.h
branches/soc-2011-tomato/source/blender/editors/mesh/editmesh_add.c
branches/soc-2011-tomato/source/blender/editors/mesh/editmesh_bvh.c
branches/soc-2011-tomato/source/blender/editors/object/object_add.c
branches/soc-2011-tomato/source/blender/editors/object/object_modifier.c
branches/soc-2011-tomato/source/blender/editors/space_clip/clip_dopesheet_draw.c
branches/soc-2011-tomato/source/blender/editors/space_view3d/drawvolume.c
branches/soc-2011-tomato/source/blender/editors/transform/transform_conversions.c
branches/soc-2011-tomato/source/blender/editors/uvedit/uvedit_parametrizer.c
branches/soc-2011-tomato/source/blender/imbuf/IMB_imbuf.h
branches/soc-2011-tomato/source/blender/imbuf/intern/rectop.c
branches/soc-2011-tomato/source/blender/makesrna/intern/rna_image.c
branches/soc-2011-tomato/source/blender/render/intern/include/pixelblending.h
branches/soc-2011-tomato/source/blender/render/intern/include/renderdatabase.h
branches/soc-2011-tomato/source/blender/render/intern/include/shading.h
branches/soc-2011-tomato/source/blender/render/intern/include/sss.h
branches/soc-2011-tomato/source/blender/render/intern/include/texture.h
branches/soc-2011-tomato/source/blender/render/intern/include/zbuf.h
branches/soc-2011-tomato/source/blender/render/intern/source/convertblender.c
branches/soc-2011-tomato/source/blender/render/intern/source/envmap.c
branches/soc-2011-tomato/source/blender/render/intern/source/imagetexture.c
branches/soc-2011-tomato/source/blender/render/intern/source/pixelblending.c
branches/soc-2011-tomato/source/blender/render/intern/source/pixelshading.c
branches/soc-2011-tomato/source/blender/render/intern/source/rayshade.c
branches/soc-2011-tomato/source/blender/render/intern/source/render_texture.c
branches/soc-2011-tomato/source/blender/render/intern/source/rendercore.c
branches/soc-2011-tomato/source/blender/render/intern/source/renderdatabase.c
branches/soc-2011-tomato/source/blender/render/intern/source/shadbuf.c
branches/soc-2011-tomato/source/blender/render/intern/source/shadeoutput.c
branches/soc-2011-tomato/source/blender/render/intern/source/sss.c
branches/soc-2011-tomato/source/blender/render/intern/source/zbuf.c
Property Changed:
----------------
branches/soc-2011-tomato/
branches/soc-2011-tomato/source/blender/editors/interface/interface.c
branches/soc-2011-tomato/source/blender/editors/space_outliner/
Property changes on: branches/soc-2011-tomato
___________________________________________________________________
Modified: svn:mergeinfo
- /branches/ge_harmony:42255,42279-42282,42286,42302,42338,42349,42616,42620,42698-42699,42739,42753,42773-42774,42832,44568,44597-44598,44793-44794
/branches/soc-2011-cucumber:37517,38166-38167,38177,38179-38180,38187,38242,38384,38387,38403-38404,38407,38968,38970,38973,39045,40845,42997-42998,43439
/branches/vgroup_modifiers:38694-39989
/trunk/blender:36831-47047
+ /branches/ge_harmony:42255,42279-42282,42286,42302,42338,42349,42616,42620,42698-42699,42739,42753,42773-42774,42832,44568,44597-44598,44793-44794
/branches/soc-2011-cucumber:37517,38166-38167,38177,38179-38180,38187,38242,38384,38387,38403-38404,38407,38968,38970,38973,39045,40845,42997-42998,43439
/branches/vgroup_modifiers:38694-39989
/trunk/blender:36831-47058
Modified: branches/soc-2011-tomato/intern/smoke/intern/FLUID_3D.cpp
===================================================================
--- branches/soc-2011-tomato/intern/smoke/intern/FLUID_3D.cpp 2012-05-26 22:22:45 UTC (rev 47058)
+++ branches/soc-2011-tomato/intern/smoke/intern/FLUID_3D.cpp 2012-05-26 22:31:28 UTC (rev 47059)
@@ -153,11 +153,11 @@
{
// bottom slab
index = x + y * _xRes;
- if(_domainBcBottom==1) _obstacles[index] = 1;
+ if(_domainBcBottom) _obstacles[index] = 1;
// top slab
index += _totalCells - _slabSize;
- if(_domainBcTop==1) _obstacles[index] = 1;
+ if(_domainBcTop) _obstacles[index] = 1;
}
for (int z = 0; z < _zRes; z++)
@@ -165,11 +165,11 @@
{
// front slab
index = x + z * _slabSize;
- if(_domainBcFront==1) _obstacles[index] = 1;
+ if(_domainBcFront) _obstacles[index] = 1;
// back slab
index += _slabSize - _xRes;
- if(_domainBcBack==1) _obstacles[index] = 1;
+ if(_domainBcBack) _obstacles[index] = 1;
}
for (int z = 0; z < _zRes; z++)
@@ -177,11 +177,11 @@
{
// left slab
index = y * _xRes + z * _slabSize;
- if(_domainBcLeft==1) _obstacles[index] = 1;
+ if(_domainBcLeft) _obstacles[index] = 1;
// right slab
index += _xRes - 1;
- if(_domainBcRight==1) _obstacles[index] = 1;
+ if(_domainBcRight) _obstacles[index] = 1;
}
}
@@ -449,48 +449,7 @@
// set side obstacles
- int index;
- for (int y = 0; y < _yRes; y++)
- for (int x = 0; x < _xRes; x++)
- {
- // front slab
- index = x + y * _xRes;
- if(_domainBcBottom==1) _obstacles[index] = 1;
- else _obstacles[index] = 0;
-
- // back slab
- index += _totalCells - _slabSize;
- if(_domainBcTop==1) _obstacles[index] = 1;
- else _obstacles[index] = 0;
- }
-
- for (int z = 0; z < _zRes; z++)
- for (int x = 0; x < _xRes; x++)
- {
- // bottom slab
- index = x + z * _slabSize;
- if(_domainBcFront==1) _obstacles[index] = 1;
- else _obstacles[index] = 0;
-
- // top slab
- index += _slabSize - _xRes;
- if(_domainBcBack==1) _obstacles[index] = 1;
- else _obstacles[index] = 0;
- }
-
- for (int z = 0; z < _zRes; z++)
- for (int y = 0; y < _yRes; y++)
- {
- // left slab
- index = y * _xRes + z * _slabSize;
- if(_domainBcLeft==1) _obstacles[index] = 1;
- else _obstacles[index] = 0;
-
- // right slab
- index += _xRes - 1;
- if(_domainBcRight==1) _obstacles[index] = 1;
- else _obstacles[index] = 0;
- }
+ setBorderObstacles();
}
//////////////////////////////////////////////////////////////////////
@@ -813,13 +772,13 @@
setObstacleBoundaries(_pressure, 0, _zRes);
// copy out the boundaries
- if(_domainBcLeft == 0) setNeumannX(_xVelocity, _res, 0, _zRes);
+ if(!_domainBcLeft) setNeumannX(_xVelocity, _res, 0, _zRes);
else setZeroX(_xVelocity, _res, 0, _zRes);
- if(_domainBcFront == 0) setNeumannY(_yVelocity, _res, 0, _zRes);
+ if(!_domainBcFront) setNeumannY(_yVelocity, _res, 0, _zRes);
else setZeroY(_yVelocity, _res, 0, _zRes);
- if(_domainBcTop == 0) setNeumannZ(_zVelocity, _res, 0, _zRes);
+ if(!_domainBcTop) setNeumannZ(_zVelocity, _res, 0, _zRes);
else setZeroZ(_zVelocity, _res, 0, _zRes);
/*
@@ -1369,13 +1328,13 @@
{
Vec3Int res = Vec3Int(_xRes,_yRes,_zRes);
- if(_domainBcLeft == 0) copyBorderX(_xVelocityOld, res, zBegin, zEnd);
+ if(!_domainBcLeft) copyBorderX(_xVelocityOld, res, zBegin, zEnd);
else setZeroX(_xVelocityOld, res, zBegin, zEnd);
- if(_domainBcFront == 0) copyBorderY(_yVelocityOld, res, zBegin, zEnd);
+ if(!_domainBcFront) copyBorderY(_yVelocityOld, res, zBegin, zEnd);
else setZeroY(_yVelocityOld, res, zBegin, zEnd);
- if(_domainBcTop == 0) copyBorderZ(_zVelocityOld, res, zBegin, zEnd);
+ if(!_domainBcTop) copyBorderZ(_zVelocityOld, res, zBegin, zEnd);
else setZeroZ(_zVelocityOld, res, zBegin, zEnd);
}
@@ -1423,13 +1382,13 @@
advectFieldMacCormack2(dt0, _xVelocityOld, _yVelocityOld, _zVelocityOld, _yVelocityOld, _yVelocityTemp, _yVelocity, t1, res, _obstacles, zBegin, zEnd);
advectFieldMacCormack2(dt0, _xVelocityOld, _yVelocityOld, _zVelocityOld, _zVelocityOld, _zVelocityTemp, _zVelocity, t1, res, _obstacles, zBegin, zEnd);
- if(_domainBcLeft == 0) copyBorderX(_xVelocityTemp, res, zBegin, zEnd);
+ if(!_domainBcLeft) copyBorderX(_xVelocityTemp, res, zBegin, zEnd);
else setZeroX(_xVelocityTemp, res, zBegin, zEnd);
- if(_domainBcFront == 0) copyBorderY(_yVelocityTemp, res, zBegin, zEnd);
+ if(!_domainBcFront) copyBorderY(_yVelocityTemp, res, zBegin, zEnd);
else setZeroY(_yVelocityTemp, res, zBegin, zEnd);
- if(_domainBcTop == 0) copyBorderZ(_zVelocityTemp, res, zBegin, zEnd);
+ if(!_domainBcTop) copyBorderZ(_zVelocityTemp, res, zBegin, zEnd);
else setZeroZ(_zVelocityTemp, res, zBegin, zEnd);
setZeroBorder(_density, res, zBegin, zEnd);
Modified: branches/soc-2011-tomato/intern/smoke/intern/FLUID_3D_STATIC.cpp
===================================================================
--- branches/soc-2011-tomato/intern/smoke/intern/FLUID_3D_STATIC.cpp 2012-05-26 22:22:45 UTC (rev 47058)
+++ branches/soc-2011-tomato/intern/smoke/intern/FLUID_3D_STATIC.cpp 2012-05-26 22:31:28 UTC (rev 47059)
@@ -92,19 +92,15 @@
// left slab
index = y * res[0] + z * slabSize;
field[index] = field[index + 2];
+ /* only allow outwards flux */
+ if(field[index]>0.) field[index] = 0.;
+ index += 1;
+ if(field[index]>0.) field[index] = 0.;
// right slab
- index += res[0] - 1;
+ index = y * res[0] + z * slabSize + res[0] - 1;
field[index] = field[index - 2];
- }
-
- // fix, force top slab to only allow outwards flux
- for (int y = 0; y < res[1]; y++)
- for (int z = zBegin; z < zEnd; z++)
- {
- // top slab
- index = y * res[0] + z * slabSize;
- index += res[0] - 1;
+ /* only allow outwards flux */
if(field[index]<0.) field[index] = 0.;
index -= 1;
if(field[index]<0.) field[index] = 0.;
@@ -121,27 +117,22 @@
for (int z = zBegin; z < zEnd; z++)
for (int x = 0; x < res[0]; x++)
{
- // bottom slab
+ // front slab
index = x + z * slabSize;
field[index] = field[index + 2 * res[0]];
+ /* only allow outwards flux */
+ if(field[index]>0.) field[index] = 0.;
+ index += res[0];
+ if(field[index]>0.) field[index] = 0.;
- // top slab
- index += slabSize - res[0];
+ // back slab
+ index = x + z * slabSize + slabSize - res[0];
field[index] = field[index - 2 * res[0]];
- }
-
- // fix, force top slab to only allow outwards flux
- for (int z = zBegin; z < zEnd; z++)
- for (int x = 0; x < res[0]; x++)
- {
- // top slab
- index = x + z * slabSize;
- index += slabSize - res[0];
+ /* only allow outwards flux */
if(field[index]<0.) field[index] = 0.;
index -= res[0];
if(field[index]<0.) field[index] = 0.;
}
-
}
//////////////////////////////////////////////////////////////////////
@@ -154,43 +145,33 @@
const int cellsslab = totalCells - slabSize;
int index;
- index = 0;
- if (zBegin == 0)
- for (int y = 0; y < res[1]; y++)
- for (int x = 0; x < res[0]; x++, index++)
- {
- // front slab
- field[index] = field[index + 2 * slabSize];
- }
+ if (zBegin == 0) {
+ for (int y = 0; y < res[1]; y++)
+ for (int x = 0; x < res[0]; x++)
+ {
+ // front slab
+ index = x + y * res[0];
+ field[index] = field[index + 2 * slabSize];
+ /* only allow outwards flux */
+ if(field[index]>0.) field[index] = 0.;
+ index += slabSize;
+ if(field[index]>0.) field[index] = 0.;
+ }
+ }
- if (zEnd == res[2])
- {
- index = 0;
- int indexx = 0;
-
- for (int y = 0; y < res[1]; y++)
- for (int x = 0; x < res[0]; x++, index++)
- {
-
- // back slab
- indexx = index + cellsslab;
- field[indexx] = field[indexx - 2 * slabSize];
- }
-
-
- // fix, force top slab to only allow outwards flux
- for (int y = 0; y < res[1]; y++)
- for (int x = 0; x < res[0]; x++)
- {
- // top slab
- index = x + y * res[0];
- index += cellsslab;
- if(field[index]<0.) field[index] = 0.;
- index -= slabSize;
- if(field[index]<0.) field[index] = 0.;
- }
-
- } // zEnd == res[2]
+ if (zEnd == res[2]) {
+ for (int y = 0; y < res[1]; y++)
+ for (int x = 0; x < res[0]; x++)
+ {
+ // back slab
+ index = x + y * res[0] + cellsslab;
+ field[index] = field[index - 2 * slabSize];
+ /* only allow outwards flux */
+ if(field[index]<0.) field[index] = 0.;
+ index -= slabSize;
+ if(field[index]<0.) field[index] = 0.;
+ }
+ }
}
Modified: branches/soc-2011-tomato/source/blender/blenkernel/intern/armature.c
===================================================================
--- branches/soc-2011-tomato/source/blender/blenkernel/intern/armature.c 2012-05-26 22:22:45 UTC (rev 47058)
+++ branches/soc-2011-tomato/source/blender/blenkernel/intern/armature.c 2012-05-26 22:31:28 UTC (rev 47059)
@@ -734,7 +734,7 @@
}
static float dist_bone_deform(bPoseChannel *pchan, bPoseChanDeform *pdef_info, float vec[3], DualQuat *dq,
- float mat[][3], float *co)
+ float mat[][3], const float co[3])
{
Bone *bone = pchan->bone;
float fac, contrib = 0.0;
@@ -781,7 +781,7 @@
}
static void pchan_bone_deform(bPoseChannel *pchan, bPoseChanDeform *pdef_info, float weight, float vec[3], DualQuat *dq,
- float mat[][3], float *co, float *contrib)
+ float mat[][3], const float co[3], float *contrib)
{
float cop[3], bbonemat[3][3];
DualQuat bbonedq;
Modified: branches/soc-2011-tomato/source/blender/blenkernel/intern/image.c
===================================================================
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list