[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [48154] branches/soc-2011-tomato: svn merge ^/trunk/blender -r48147:48153
Campbell Barton
ideasman42 at gmail.com
Thu Jun 21 10:07:51 CEST 2012
Revision: 48154
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=48154
Author: campbellbarton
Date: 2012-06-21 08:07:49 +0000 (Thu, 21 Jun 2012)
Log Message:
-----------
svn merge ^/trunk/blender -r48147:48153
Revision Links:
--------------
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=48147
Modified Paths:
--------------
branches/soc-2011-tomato/intern/cycles/app/cycles_xml.cpp
branches/soc-2011-tomato/release/scripts/startup/bl_ui/properties_texture.py
branches/soc-2011-tomato/source/blender/blenkernel/BKE_blender.h
branches/soc-2011-tomato/source/blender/blenkernel/intern/ipo.c
branches/soc-2011-tomato/source/blender/blenloader/intern/readfile.c
branches/soc-2011-tomato/source/blender/blenloader/intern/versioning_250.c
branches/soc-2011-tomato/source/blender/compositor/nodes/COM_DilateErodeNode.cpp
branches/soc-2011-tomato/source/blender/compositor/operations/COM_BlurBaseOperation.cpp
branches/soc-2011-tomato/source/blender/compositor/operations/COM_BlurBaseOperation.h
branches/soc-2011-tomato/source/blender/compositor/operations/COM_GaussianAlphaXBlurOperation.cpp
branches/soc-2011-tomato/source/blender/compositor/operations/COM_GaussianAlphaXBlurOperation.h
branches/soc-2011-tomato/source/blender/compositor/operations/COM_GaussianAlphaYBlurOperation.cpp
branches/soc-2011-tomato/source/blender/compositor/operations/COM_GaussianAlphaYBlurOperation.h
branches/soc-2011-tomato/source/blender/editors/space_node/drawnode.c
branches/soc-2011-tomato/source/blender/makesdna/DNA_node_types.h
branches/soc-2011-tomato/source/blender/makesrna/RNA_enum_types.h
branches/soc-2011-tomato/source/blender/makesrna/intern/rna_color.c
branches/soc-2011-tomato/source/blender/makesrna/intern/rna_nodetree.c
branches/soc-2011-tomato/source/blender/makesrna/intern/rna_scene.c
branches/soc-2011-tomato/source/blender/nodes/composite/nodes/node_composite_dilate.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-48147
+ /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-48153
Modified: branches/soc-2011-tomato/intern/cycles/app/cycles_xml.cpp
===================================================================
--- branches/soc-2011-tomato/intern/cycles/app/cycles_xml.cpp 2012-06-21 08:02:18 UTC (rev 48153)
+++ branches/soc-2011-tomato/intern/cycles/app/cycles_xml.cpp 2012-06-21 08:07:49 UTC (rev 48154)
@@ -277,7 +277,7 @@
xml_read_bool(&integrator->transparent_shadows, node, "transparent_shadows");
xml_read_bool(&integrator->no_caustics, node, "no_caustics");
- xml_read_float(&integrator->blur_glossy, node, "blur_glossy");
+ xml_read_float(&integrator->filter_glossy, node, "blur_glossy");
xml_read_int(&integrator->seed, node, "seed");
xml_read_float(&integrator->sample_clamp, node, "sample_clamp");
Modified: branches/soc-2011-tomato/release/scripts/startup/bl_ui/properties_texture.py
===================================================================
--- branches/soc-2011-tomato/release/scripts/startup/bl_ui/properties_texture.py 2012-06-21 08:02:18 UTC (rev 48153)
+++ branches/soc-2011-tomato/release/scripts/startup/bl_ui/properties_texture.py 2012-06-21 08:07:49 UTC (rev 48154)
@@ -23,6 +23,7 @@
from bpy.types import (Brush,
Lamp,
Material,
+ Object,
ParticleSettings,
Texture,
World)
@@ -80,6 +81,15 @@
return idblock
+def id_tex_datablock(bid):
+ if isinstance(bid, Object):
+ if bid.type == 'LAMP':
+ return bid.data
+ return bid.active_material
+
+ return bid
+
+
class TextureButtonsPanel():
bl_space_type = 'PROPERTIES'
bl_region_type = 'WINDOW'
@@ -114,7 +124,7 @@
pin_id = space.pin_id
if space.use_pin_id and not isinstance(pin_id, Texture):
- idblock = pin_id
+ idblock = id_tex_datablock(pin_id)
pin_id = None
if not space.use_pin_id:
Modified: branches/soc-2011-tomato/source/blender/blenkernel/BKE_blender.h
===================================================================
--- branches/soc-2011-tomato/source/blender/blenkernel/BKE_blender.h 2012-06-21 08:02:18 UTC (rev 48153)
+++ branches/soc-2011-tomato/source/blender/blenkernel/BKE_blender.h 2012-06-21 08:07:49 UTC (rev 48154)
@@ -42,7 +42,7 @@
* and keep comment above the defines.
* Use STRINGIFY() rather than defining with quotes */
#define BLENDER_VERSION 263
-#define BLENDER_SUBVERSION 12
+#define BLENDER_SUBVERSION 13
#define BLENDER_MINVERSION 250
#define BLENDER_MINSUBVERSION 0
Modified: branches/soc-2011-tomato/source/blender/blenkernel/intern/ipo.c
===================================================================
--- branches/soc-2011-tomato/source/blender/blenkernel/intern/ipo.c 2012-06-21 08:02:18 UTC (rev 48153)
+++ branches/soc-2011-tomato/source/blender/blenkernel/intern/ipo.c 2012-06-21 08:07:49 UTC (rev 48154)
@@ -46,6 +46,7 @@
/* since we have versioning code here */
#define DNA_DEPRECATED_ALLOW
+#include "DNA_actuator_types.h"
#include "DNA_anim_types.h"
#include "DNA_constraint_types.h"
#include "DNA_camera_types.h"
@@ -1753,6 +1754,24 @@
ipo_to_animdata(id, ob->ipo, NULL, NULL, NULL);
ob->ipo->id.us--;
ob->ipo = NULL;
+
+ {
+ /* If we have any empty action actuators, assume they were
+ converted IPO Actuators using the object IPO */
+ bActuator *act;
+ bActionActuator *aa;
+
+ for (act = ob->actuators.first; act; act = act->next) {
+ /* Any actuators set to ACT_IPO at this point are actually Action Actuators that
+ need this converted IPO to finish converting the actuator. */
+ if (act->type == ACT_IPO)
+ {
+ aa = (bActionActuator*)act->data;
+ aa->act = ob->adt->action;
+ act->type = ACT_ACTION;
+ }
+ }
+ }
}
}
Modified: branches/soc-2011-tomato/source/blender/blenloader/intern/readfile.c
===================================================================
--- branches/soc-2011-tomato/source/blender/blenloader/intern/readfile.c 2012-06-21 08:02:18 UTC (rev 48153)
+++ branches/soc-2011-tomato/source/blender/blenloader/intern/readfile.c 2012-06-21 08:07:49 UTC (rev 48154)
@@ -6982,6 +6982,21 @@
}
}
+static void do_version_ntree_dilateerode_264(void *UNUSED(data), ID *UNUSED(id), bNodeTree *ntree)
+{
+ bNode *node;
+
+ for (node = ntree->nodes.first; node; node = node->next) {
+ if (node->type == CMP_NODE_DILATEERODE) {
+ if (node->storage == NULL) {
+ NodeDilateErode *data = MEM_callocN(sizeof(NodeDilateErode), __func__);
+ data->falloff = PROP_SMOOTH;
+ node->storage = data;
+ }
+ }
+ }
+}
+
static void do_versions(FileData *fd, Library *lib, Main *main)
{
/* WATCH IT!!!: pointers from libdata have not been converted */
@@ -7789,6 +7804,13 @@
ma->strand_widthfade = 0.0f;
}
+ if (main->versionfile < 263 || (main->versionfile == 263 && main->subversionfile < 13)) {
+ bNodeTreeType *ntreetype = ntreeGetType(NTREE_COMPOSIT);
+
+ if (ntreetype && ntreetype->foreach_nodetree)
+ ntreetype->foreach_nodetree(main, NULL, do_version_ntree_dilateerode_264);
+ }
+
/* WATCH IT!!!: pointers from libdata have not been converted yet here! */
/* WATCH IT 2!: Userdef struct init has to be in editors/interface/resources.c! */
Modified: branches/soc-2011-tomato/source/blender/blenloader/intern/versioning_250.c
===================================================================
--- branches/soc-2011-tomato/source/blender/blenloader/intern/versioning_250.c 2012-06-21 08:02:18 UTC (rev 48153)
+++ branches/soc-2011-tomato/source/blender/blenloader/intern/versioning_250.c 2012-06-21 08:07:49 UTC (rev 48154)
@@ -2558,11 +2558,11 @@
for (ob = main->object.first; ob; ob = ob->id.next) {
for (act = ob->actuators.first; act; act = act->next) {
if (act->type == ACT_IPO) {
- // Create the new actuator
+ /* Create the new actuator */
ia = act->data;
aa = MEM_callocN(sizeof(bActionActuator), "fcurve -> action actuator do_version");
- // Copy values
+ /* Copy values */
aa->type = ia->type;
aa->flag = ia->flag;
aa->sta = ia->sta;
@@ -2572,12 +2572,18 @@
if (ob->adt)
aa->act = ob->adt->action;
- // Get rid of the old actuator
+ /* Get rid of the old actuator */
MEM_freeN(ia);
- // Assign the new actuator
+ /* Assign the new actuator */
act->data = aa;
act->type = act->otype = ACT_ACTION;
+
+ /* Fix for converting 2.4x files: if we don't have an action, but we have an
+ object IPO, then leave the actuator as an IPO actuator for now and let the
+ IPO conversion code handle it */
+ if (ob->ipo && !aa->act)
+ act->type = ACT_IPO;
}
else if (act->type == ACT_SHAPEACTION) {
act->type = act->otype = ACT_ACTION;
Modified: branches/soc-2011-tomato/source/blender/compositor/nodes/COM_DilateErodeNode.cpp
===================================================================
--- branches/soc-2011-tomato/source/blender/compositor/nodes/COM_DilateErodeNode.cpp 2012-06-21 08:02:18 UTC (rev 48153)
+++ branches/soc-2011-tomato/source/blender/compositor/nodes/COM_DilateErodeNode.cpp 2012-06-21 08:07:49 UTC (rev 48154)
@@ -117,6 +117,12 @@
#endif
operationx->setSubtract(editorNode->custom2 < 0);
operationy->setSubtract(editorNode->custom2 < 0);
+
+ if (editorNode->storage) {
+ NodeDilateErode *data = (NodeDilateErode *)editorNode->storage;
+ operationx->setFalloff(data->falloff);
+ operationy->setFalloff(data->falloff);
+ }
}
else {
if (editorNode->custom2 > 0) {
Modified: branches/soc-2011-tomato/source/blender/compositor/operations/COM_BlurBaseOperation.cpp
===================================================================
--- branches/soc-2011-tomato/source/blender/compositor/operations/COM_BlurBaseOperation.cpp 2012-06-21 08:02:18 UTC (rev 48153)
+++ branches/soc-2011-tomato/source/blender/compositor/operations/COM_BlurBaseOperation.cpp 2012-06-21 08:07:49 UTC (rev 48154)
@@ -91,7 +91,7 @@
/* normalized distance from the current (inverted so 1.0 is close and 0.0 is far)
* 'ease' is applied after, looks nicer */
-float *BlurBaseOperation::make_dist_fac_inverse(int rad)
+float *BlurBaseOperation::make_dist_fac_inverse(int rad, int falloff)
{
float *dist_fac_invert, val;
int i, n;
@@ -103,9 +103,26 @@
for (i = -rad; i <= rad; i++) {
val = 1.0f - fabsf(((float)i / (float)rad));
- /* ease - gives less hard lines for dilate/erode feather */
- val = (3.0f * val * val - 2.0f * val * val * val);
-
+ /* keep in sync with proportional_falloff_curve_only_items */
+ switch (falloff) {
+ case PROP_SMOOTH:
+ /* ease - gives less hard lines for dilate/erode feather */
+ val = (3.0f * val * val - 2.0f * val * val * val);
+ break;
+ case PROP_SPHERE:
+ val = sqrtf(2.0f * val - val * val);
+ break;
+ case PROP_ROOT:
+ val = sqrtf(val);
+ break;
+ case PROP_SHARP:
+ val = val * val;
+ break;
+ case PROP_LIN:
+ default:
+ /* nothing */
+ break;
+ }
dist_fac_invert[i + rad] = val;
}
Modified: branches/soc-2011-tomato/source/blender/compositor/operations/COM_BlurBaseOperation.h
===================================================================
--- branches/soc-2011-tomato/source/blender/compositor/operations/COM_BlurBaseOperation.h 2012-06-21 08:02:18 UTC (rev 48153)
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list