[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15762] branches/soc-2008-unclezeiv/source : svn merge -r 15714:15760 https://svn.blender.org/svnroot/bf-blender/trunk /blender
Davide Vercelli
davide.vercelli at gmail.com
Fri Jul 25 18:19:17 CEST 2008
Revision: 15762
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=15762
Author: unclezeiv
Date: 2008-07-25 18:19:15 +0200 (Fri, 25 Jul 2008)
Log Message:
-----------
svn merge -r 15714:15760 https://svn.blender.org/svnroot/bf-blender/trunk/blender
Modified Paths:
--------------
branches/soc-2008-unclezeiv/source/blender/blenkernel/BKE_idprop.h
branches/soc-2008-unclezeiv/source/blender/blenkernel/bad_level_call_stubs/stubs.c
branches/soc-2008-unclezeiv/source/blender/blenkernel/intern/idprop.c
branches/soc-2008-unclezeiv/source/blender/blenkernel/intern/softbody.c
branches/soc-2008-unclezeiv/source/blender/blenloader/intern/readfile.c
branches/soc-2008-unclezeiv/source/blender/blenloader/intern/writefile.c
branches/soc-2008-unclezeiv/source/blender/include/BDR_gpencil.h
branches/soc-2008-unclezeiv/source/blender/makesdna/DNA_ID.h
branches/soc-2008-unclezeiv/source/blender/makesdna/DNA_actuator_types.h
branches/soc-2008-unclezeiv/source/blender/makesdna/DNA_gpencil_types.h
branches/soc-2008-unclezeiv/source/blender/nodes/intern/SHD_nodes/SHD_material.c
branches/soc-2008-unclezeiv/source/blender/nodes/intern/SHD_util.c
branches/soc-2008-unclezeiv/source/blender/nodes/intern/SHD_util.h
branches/soc-2008-unclezeiv/source/blender/python/api2_2x/IDProp.c
branches/soc-2008-unclezeiv/source/blender/python/api2_2x/doc/IDProp.py
branches/soc-2008-unclezeiv/source/blender/src/buttons_editing.c
branches/soc-2008-unclezeiv/source/blender/src/buttons_logic.c
branches/soc-2008-unclezeiv/source/blender/src/drawaction.c
branches/soc-2008-unclezeiv/source/blender/src/drawgpencil.c
branches/soc-2008-unclezeiv/source/blender/src/editnode.c
branches/soc-2008-unclezeiv/source/blender/src/gpencil.c
branches/soc-2008-unclezeiv/source/blender/src/interface_draw.c
branches/soc-2008-unclezeiv/source/blender/src/outliner.c
branches/soc-2008-unclezeiv/source/blender/src/space.c
branches/soc-2008-unclezeiv/source/gameengine/Converter/BL_BlenderDataConversion.cpp
branches/soc-2008-unclezeiv/source/gameengine/Converter/BL_ShapeActionActuator.cpp
branches/soc-2008-unclezeiv/source/gameengine/Converter/BL_ShapeActionActuator.h
branches/soc-2008-unclezeiv/source/gameengine/Converter/KX_ConvertActuators.cpp
branches/soc-2008-unclezeiv/source/gameengine/Converter/KX_IpoConvert.cpp
branches/soc-2008-unclezeiv/source/gameengine/Converter/KX_IpoConvert.h
branches/soc-2008-unclezeiv/source/gameengine/GameLogic/SCA_ActuatorSensor.cpp
branches/soc-2008-unclezeiv/source/gameengine/GameLogic/SCA_ActuatorSensor.h
branches/soc-2008-unclezeiv/source/gameengine/GameLogic/SCA_ISensor.cpp
branches/soc-2008-unclezeiv/source/gameengine/GameLogic/SCA_ISensor.h
branches/soc-2008-unclezeiv/source/gameengine/Ketsji/KX_ConstraintActuator.cpp
branches/soc-2008-unclezeiv/source/gameengine/Ketsji/KX_ConstraintActuator.h
branches/soc-2008-unclezeiv/source/gameengine/Ketsji/KX_GameObject.cpp
branches/soc-2008-unclezeiv/source/gameengine/Ketsji/KX_GameObject.h
branches/soc-2008-unclezeiv/source/gameengine/Ketsji/KX_IpoActuator.cpp
branches/soc-2008-unclezeiv/source/gameengine/Ketsji/KX_IpoActuator.h
branches/soc-2008-unclezeiv/source/gameengine/Ketsji/KX_MaterialIpoController.cpp
branches/soc-2008-unclezeiv/source/gameengine/Ketsji/KX_MaterialIpoController.h
branches/soc-2008-unclezeiv/source/gameengine/Ketsji/KX_ObjectActuator.cpp
branches/soc-2008-unclezeiv/source/gameengine/Ketsji/KX_ObjectActuator.h
branches/soc-2008-unclezeiv/source/gameengine/Ketsji/KX_PythonInit.cpp
branches/soc-2008-unclezeiv/source/gameengine/Ketsji/KX_TrackToActuator.cpp
branches/soc-2008-unclezeiv/source/gameengine/PyDoc/KX_ConstraintActuator.py
branches/soc-2008-unclezeiv/source/gameengine/PyDoc/KX_IpoActuator.py
branches/soc-2008-unclezeiv/source/gameengine/PyDoc/KX_ObjectActuator.py
branches/soc-2008-unclezeiv/source/gameengine/PyDoc/SCA_ISensor.py
branches/soc-2008-unclezeiv/source/gameengine/Rasterizer/RAS_IPolygonMaterial.cpp
branches/soc-2008-unclezeiv/source/gameengine/Rasterizer/RAS_IPolygonMaterial.h
branches/soc-2008-unclezeiv/source/gameengine/Rasterizer/RAS_MeshObject.cpp
branches/soc-2008-unclezeiv/source/gameengine/Rasterizer/RAS_MeshObject.h
Added Paths:
-----------
branches/soc-2008-unclezeiv/source/gameengine/PyDoc/BL_ShapeActionActuator.py
branches/soc-2008-unclezeiv/source/gameengine/PyDoc/KX_ActuatorSensor.py
branches/soc-2008-unclezeiv/source/gameengine/PyDoc/KX_StateActuator.py
Modified: branches/soc-2008-unclezeiv/source/blender/blenkernel/BKE_idprop.h
===================================================================
--- branches/soc-2008-unclezeiv/source/blender/blenkernel/BKE_idprop.h 2008-07-25 16:09:35 UTC (rev 15761)
+++ branches/soc-2008-unclezeiv/source/blender/blenkernel/BKE_idprop.h 2008-07-25 16:19:15 UTC (rev 15762)
@@ -46,6 +46,7 @@
typedef union {
int i;
float f;
+ double d;
char *str;
struct ID *id;
struct {
Modified: branches/soc-2008-unclezeiv/source/blender/blenkernel/bad_level_call_stubs/stubs.c
===================================================================
--- branches/soc-2008-unclezeiv/source/blender/blenkernel/bad_level_call_stubs/stubs.c 2008-07-25 16:09:35 UTC (rev 15761)
+++ branches/soc-2008-unclezeiv/source/blender/blenkernel/bad_level_call_stubs/stubs.c 2008-07-25 16:19:15 UTC (rev 15762)
@@ -1,4 +1,3 @@
-
/**
* $Id$
*
@@ -356,6 +355,8 @@
/* editseq.c */
Sequence *get_forground_frame_seq(int frame){return 0;};
void set_last_seq(Sequence *seq){};
+void clear_last_seq(Sequence *seq){};
+
/* modifier.c stub */
void harmonic_coordinates_bind(struct MeshDeformModifierData *mmd,
Modified: branches/soc-2008-unclezeiv/source/blender/blenkernel/intern/idprop.c
===================================================================
--- branches/soc-2008-unclezeiv/source/blender/blenkernel/intern/idprop.c 2008-07-25 16:09:35 UTC (rev 15761)
+++ branches/soc-2008-unclezeiv/source/blender/blenkernel/intern/idprop.c 2008-07-25 16:19:15 UTC (rev 15762)
@@ -54,7 +54,8 @@
sizeof(float)*16, /*Matrix type, deprecated*/
0, /*arrays don't have a fixed size*/
sizeof(ListBase), /*Group type*/
- sizeof(void*)
+ sizeof(void*),
+ sizeof(double)
};
@@ -365,10 +366,14 @@
prop = MEM_callocN(sizeof(IDProperty), "IDProperty float");
*(float*)&prop->data.val = val.f;
break;
+ case IDP_DOUBLE:
+ prop = MEM_callocN(sizeof(IDProperty), "IDProperty float");
+ *(double*)&prop->data.val = val.d;
+ break;
case IDP_ARRAY:
{
- /*for now, we only support float and int arrays*/
- if (val.array.type == IDP_FLOAT || val.array.type == IDP_INT) {
+ /*for now, we only support float and int and double arrays*/
+ if (val.array.type == IDP_FLOAT || val.array.type == IDP_INT || val.array.type == IDP_DOUBLE) {
prop = MEM_callocN(sizeof(IDProperty), "IDProperty array");
prop->len = prop->totallen = val.array.len;
prop->subtype = val.array.type;
@@ -411,6 +416,10 @@
prop->type = type;
strncpy(prop->name, name, MAX_IDPROP_NAME);
+
+ /*security null byte*/
+ prop->name[MAX_IDPROP_NAME-1] = 0;
+
return prop;
}
Modified: branches/soc-2008-unclezeiv/source/blender/blenkernel/intern/softbody.c
===================================================================
--- branches/soc-2008-unclezeiv/source/blender/blenkernel/intern/softbody.c 2008-07-25 16:09:35 UTC (rev 15761)
+++ branches/soc-2008-unclezeiv/source/blender/blenkernel/intern/softbody.c 2008-07-25 16:19:15 UTC (rev 15762)
@@ -1548,7 +1548,7 @@
/* note we don't use sb->mediafrict but use sb->aeroedge for magnitude of effect*/
if(sb->aeroedge){
float vel[3],sp[3],pr[3],force[3];
- float f,windfactor = 250.0f;
+ float f,windfactor = 10.0f;
/*see if we have wind*/
if(do_effector) {
float speed[3]={0.0f,0.0f,0.0f};
@@ -2034,7 +2034,7 @@
BodySpring *bs;
ListBase *do_effector;
float iks, ks, kd, gravity;
- float fieldfactor = 1000.0f, windfactor = 250.0f;
+ float fieldfactor = -100.0f, windfactor = 10.0f;
float tune = sb->ballstiff;
int a, b, do_deflector,do_selfcollision,do_springcollision,do_aero;
@@ -2053,7 +2053,6 @@
/* check conditions for various options */
do_deflector= query_external_colliders(ob);
- do_effector= pdInitEffectors(ob,NULL);
do_selfcollision=((ob->softflag & OB_SB_EDGES) && (sb->bspring)&& (ob->softflag & OB_SB_SELF));
do_springcollision=do_deflector && (ob->softflag & OB_SB_EDGES) &&(ob->softflag & OB_SB_EDGECOLL);
do_aero=((sb->aeroedge)&& (ob->softflag & OB_SB_EDGES));
@@ -2061,9 +2060,10 @@
iks = 1.0f/(1.0f-sb->inspring)-1.0f ;/* inner spring constants function */
bproot= sb->bpoint; /* need this for proper spring addressing */
+ if (do_springcollision || do_aero) scan_for_ext_spring_forces(ob,timenow);
+ /* after spring scan because it uses Effoctors too */
+ do_effector= pdInitEffectors(ob,NULL);
-
- if (do_springcollision || do_aero) scan_for_ext_spring_forces(ob,timenow);
if (do_deflector) {
float defforce[3];
do_deflector = sb_detect_aabb_collisionCached(defforce,ob->lay,ob,timenow);
Modified: branches/soc-2008-unclezeiv/source/blender/blenloader/intern/readfile.c
===================================================================
--- branches/soc-2008-unclezeiv/source/blender/blenloader/intern/readfile.c 2008-07-25 16:09:35 UTC (rev 15761)
+++ branches/soc-2008-unclezeiv/source/blender/blenloader/intern/readfile.c 2008-07-25 16:19:15 UTC (rev 15762)
@@ -1347,8 +1347,14 @@
prop->data.pointer = newdataadr(fd, prop->data.pointer);
if (switch_endian) {
- for (i=0; i<prop->len; i++) {
- SWITCH_INT(((int*)prop->data.pointer)[i]);
+ if (prop->subtype != IDP_DOUBLE) {
+ for (i=0; i<prop->len; i++) {
+ SWITCH_INT(((int*)prop->data.pointer)[i]);
+ }
+ } else {
+ for (i=0; i<prop->len; i++) {
+ SWITCH_LONGINT(((double*)prop->data.pointer)[i]);
+ }
}
}
}
@@ -1385,6 +1391,24 @@
case IDP_ARRAY:
IDP_DirectLinkArray(prop, switch_endian, fd);
break;
+ case IDP_DOUBLE:
+ /*erg, stupid doubles. since I'm storing them
+ in the same field as int val; val2 in the
+ IDPropertyData struct, they have to deal with
+ endianness specifically
+
+ in theory, val and val2 would've already been swapped
+ if switch_endian is true, so we have to first unswap
+ them then reswap them as a single 64-bit entity.
+ */
+
+ if (switch_endian) {
+ SWITCH_INT(prop->data.val);
+ SWITCH_INT(prop->data.val2);
+ SWITCH_LONGINT(prop->data.val);
+ }
+
+ break;
}
}
Modified: branches/soc-2008-unclezeiv/source/blender/blenloader/intern/writefile.c
===================================================================
--- branches/soc-2008-unclezeiv/source/blender/blenloader/intern/writefile.c 2008-07-25 16:09:35 UTC (rev 15761)
+++ branches/soc-2008-unclezeiv/source/blender/blenloader/intern/writefile.c 2008-07-25 16:19:15 UTC (rev 15762)
@@ -533,6 +533,7 @@
if(part->id.us>0 || wd->current) {
/* write LibData */
writestruct(wd, ID_PA, "ParticleSettings", 1, part);
+ if (part->id.properties) IDP_WriteProperty(part->id.properties, wd);
writestruct(wd, DATA, "PartDeflect", 1, part->pd);
}
part= part->id.next;
Modified: branches/soc-2008-unclezeiv/source/blender/include/BDR_gpencil.h
===================================================================
--- branches/soc-2008-unclezeiv/source/blender/include/BDR_gpencil.h 2008-07-25 16:09:35 UTC (rev 15761)
+++ branches/soc-2008-unclezeiv/source/blender/include/BDR_gpencil.h 2008-07-25 16:19:15 UTC (rev 15762)
@@ -69,6 +69,6 @@
void gpencil_delete_menu(void);
//short gpencil_paint(short mousebutton);
-short gpencil_do_paint(struct ScrArea *sa);
+short gpencil_do_paint(struct ScrArea *sa, short mousebutton);
#endif /* BDR_GPENCIL_H */
Modified: branches/soc-2008-unclezeiv/source/blender/makesdna/DNA_ID.h
===================================================================
--- branches/soc-2008-unclezeiv/source/blender/makesdna/DNA_ID.h 2008-07-25 16:09:35 UTC (rev 15761)
+++ branches/soc-2008-unclezeiv/source/blender/makesdna/DNA_ID.h 2008-07-25 16:19:15 UTC (rev 15762)
@@ -46,7 +46,7 @@
typedef struct IDPropertyData {
void *pointer;
ListBase group;
- int val, pad;
+ int val, val2; /*note, we actually fit a double into these two ints*/
} IDPropertyData;
typedef struct IDProperty {
@@ -77,6 +77,7 @@
/*the ID link property type hasn't been implemented yet, this will require
some cleanup of blenkernel, most likely.*/
#define IDP_ID 7
+#define IDP_DOUBLE 8
/*add any future new id property types here.*/
Modified: branches/soc-2008-unclezeiv/source/blender/makesdna/DNA_actuator_types.h
===================================================================
--- branches/soc-2008-unclezeiv/source/blender/makesdna/DNA_actuator_types.h 2008-07-25 16:09:35 UTC (rev 15761)
+++ branches/soc-2008-unclezeiv/source/blender/makesdna/DNA_actuator_types.h 2008-07-25 16:19:15 UTC (rev 15762)
@@ -368,9 +368,9 @@
#define ACT_CONST_DIRPX 1
#define ACT_CONST_DIRPY 2
#define ACT_CONST_DIRPZ 4
-#define ACT_CONST_DIRMX 8
-#define ACT_CONST_DIRMY 16
-#define ACT_CONST_DIRMZ 32
+#define ACT_CONST_DIRNX 8
+#define ACT_CONST_DIRNY 16
+#define ACT_CONST_DIRNZ 32
/* constraint type */
#define ACT_CONST_TYPE_LOC 0
Modified: branches/soc-2008-unclezeiv/source/blender/makesdna/DNA_gpencil_types.h
===================================================================
--- branches/soc-2008-unclezeiv/source/blender/makesdna/DNA_gpencil_types.h 2008-07-25 16:09:35 UTC (rev 15761)
+++ branches/soc-2008-unclezeiv/source/blender/makesdna/DNA_gpencil_types.h 2008-07-25 16:19:15 UTC (rev 15762)
@@ -59,6 +59,8 @@
#define GP_STROKE_3DSPACE (1<<0)
/* stroke is in 2d-space */
#define GP_STROKE_2DSPACE (1<<1)
+ /* stroke is an "eraser" stroke */
+#define GP_STROKE_ERASER (1<<2)
/* Grease-Pencil Annotations - 'Frame'
@@ -127,12 +129,12 @@
} bGPdata;
/* bGPdata->flag */
- /* draw this datablock's data (not used) */
-#define GP_DATA_DISP (1<<0)
+ /* don't allow painting to occur at all */
+#define GP_DATA_LMBPLOCK (1<<0)
/* show debugging info in viewport (i.e. status print) */
#define GP_DATA_DISPINFO (1<<1)
/* in Action Editor, show as expanded channel */
-#define GP_DATA_EXPAND (1<<2)
+#define GP_DATA_EXPAND (1<<2)
/* is the block overriding all clicks? */
#define GP_DATA_EDITPAINT (1<<3)
/* new strokes are added in viewport space */
Modified: branches/soc-2008-unclezeiv/source/blender/nodes/intern/SHD_nodes/SHD_material.c
===================================================================
--- branches/soc-2008-unclezeiv/source/blender/nodes/intern/SHD_nodes/SHD_material.c 2008-07-25 16:09:35 UTC (rev 15761)
+++ branches/soc-2008-unclezeiv/source/blender/nodes/intern/SHD_nodes/SHD_material.c 2008-07-25 16:19:15 UTC (rev 15762)
@@ -54,7 +54,6 @@
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list