[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [17677] branches/blender2.5/blender/source /blender/makesrna/intern: RNA - Wrapped a few more simple Object transforms .

Joshua Leung aligorith at gmail.com
Tue Dec 2 11:10:07 CET 2008


Revision: 17677
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=17677
Author:   aligorith
Date:     2008-12-02 11:10:07 +0100 (Tue, 02 Dec 2008)

Log Message:
-----------
RNA - Wrapped a few more simple Object transforms.

Note: Rotations are still exposed directly in radians. We should probably do some wrapping around this, perhaps at UI-level?

Modified Paths:
--------------
    branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c
    branches/blender2.5/blender/source/blender/makesrna/intern/rna_object.c

Modified: branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c	2008-12-02 09:43:23 UTC (rev 17676)
+++ branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c	2008-12-02 10:10:07 UTC (rev 17677)
@@ -625,6 +625,7 @@
 		case PROP_COLOR: return "PROP_COLOR";
 		case PROP_VECTOR: return "PROP_VECTOR";
 		case PROP_MATRIX: return "PROP_MATRIX";
+		case PROP_ROTATION: return "PROP_ROTATION";
 		default: return "PROP_UNKNOWN";
 	}
 }

Modified: branches/blender2.5/blender/source/blender/makesrna/intern/rna_object.c
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/intern/rna_object.c	2008-12-02 09:43:23 UTC (rev 17676)
+++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_object.c	2008-12-02 10:10:07 UTC (rev 17677)
@@ -74,6 +74,14 @@
 
 	prop= RNA_def_property(srna, "loc", PROP_FLOAT, PROP_VECTOR);
 	RNA_def_property_ui_text(prop, "Location", "");
+	
+	//prop= RNA_def_property(srna, "rot", PROP_FLOAT, PROP_ROTATION);
+	//RNA_def_property_ui_text(prop, "Rotation", "");
+	prop= RNA_def_property(srna, "rot", PROP_FLOAT, PROP_VECTOR);
+	RNA_def_property_ui_text(prop, "Rotation", "");
+	
+	prop= RNA_def_property(srna, "size", PROP_FLOAT, PROP_VECTOR);
+	RNA_def_property_ui_text(prop, "Scale", "");
 
 	prop= RNA_def_property(srna, "modifiers", PROP_COLLECTION, PROP_NONE);
 	RNA_def_property_struct_type(prop, "ModifierData");





More information about the Bf-blender-cvs mailing list