[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [19096] branches/blender2.5/blender/source /blender/makesrna: Gave RNA to timeline markers.

Roland Hess me at harkyman.com
Tue Feb 24 04:07:05 CET 2009


Revision: 19096
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=19096
Author:   harkyman
Date:     2009-02-24 04:06:23 +0100 (Tue, 24 Feb 2009)

Log Message:
-----------
Gave RNA to timeline markers. Updated both Scene and Action RNA for standard and pose markers.

Modified Paths:
--------------
    branches/blender2.5/blender/source/blender/makesrna/RNA_access.h
    branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c
    branches/blender2.5/blender/source/blender/makesrna/intern/rna_action.c
    branches/blender2.5/blender/source/blender/makesrna/intern/rna_internal.h
    branches/blender2.5/blender/source/blender/makesrna/intern/rna_scene.c

Added Paths:
-----------
    branches/blender2.5/blender/source/blender/makesrna/intern/rna_timeline.c

Modified: branches/blender2.5/blender/source/blender/makesrna/RNA_access.h
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/RNA_access.h	2009-02-24 00:45:40 UTC (rev 19095)
+++ branches/blender2.5/blender/source/blender/makesrna/RNA_access.h	2009-02-24 03:06:23 UTC (rev 19096)
@@ -252,6 +252,7 @@
 extern StructRNA RNA_ThemeUserInterface;
 extern StructRNA RNA_ThemeUserPreferences;
 extern StructRNA RNA_ThemeView3D;
+extern StructRNA RNA_TimelineMarker;
 extern StructRNA RNA_ToolSettings;
 extern StructRNA RNA_TouchSensor;
 extern StructRNA RNA_TransformSequence;

Modified: branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c	2009-02-24 00:45:40 UTC (rev 19095)
+++ branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c	2009-02-24 03:06:23 UTC (rev 19096)
@@ -1285,6 +1285,7 @@
 	{"rna_sequence.c", RNA_def_sequence},
 	{"rna_space.c", RNA_def_space},
 	{"rna_text.c", RNA_def_text},
+	{"rna_timeline.c", RNA_def_timeline_marker},
 	{"rna_sound.c", RNA_def_sound},
 	{"rna_userdef.c", RNA_def_userdef},
 	{"rna_vfont.c", RNA_def_vfont},

Modified: branches/blender2.5/blender/source/blender/makesrna/intern/rna_action.c
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/intern/rna_action.c	2009-02-24 00:45:40 UTC (rev 19095)
+++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_action.c	2009-02-24 03:06:23 UTC (rev 19096)
@@ -270,7 +270,7 @@
 
 	prop= RNA_def_property(srna, "pose_markers", PROP_COLLECTION, PROP_NONE);
 	RNA_def_property_collection_sdna(prop, NULL, "markers", NULL);
-	RNA_def_property_struct_type(prop, "UnknownType"); /* implement when timeline rna is wrapped */
+	RNA_def_property_struct_type(prop, "TimelineMarker");
 	RNA_def_property_ui_text(prop, "Pose Markers", "Markers specific to this Action, for labeling poses.");
 }
 

Modified: branches/blender2.5/blender/source/blender/makesrna/intern/rna_internal.h
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/intern/rna_internal.h	2009-02-24 00:45:40 UTC (rev 19095)
+++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_internal.h	2009-02-24 03:06:23 UTC (rev 19096)
@@ -135,6 +135,7 @@
 void RNA_def_space(struct BlenderRNA *brna);
 void RNA_def_text(struct BlenderRNA *brna);
 void RNA_def_texture(struct BlenderRNA *brna);
+void RNA_def_timeline_marker(struct BlenderRNA *brna);
 void RNA_def_sound(struct BlenderRNA *brna);
 void RNA_def_userdef(struct BlenderRNA *brna);
 void RNA_def_vfont(struct BlenderRNA *brna);

Modified: branches/blender2.5/blender/source/blender/makesrna/intern/rna_scene.c
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/intern/rna_scene.c	2009-02-24 00:45:40 UTC (rev 19095)
+++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_scene.c	2009-02-24 03:06:23 UTC (rev 19096)
@@ -470,6 +470,11 @@
 	RNA_def_property_struct_type(prop, "SceneRenderData");
 	RNA_def_property_ui_text(prop, "Render Data", "");
 
+	prop= RNA_def_property(srna, "timeline_markers", PROP_COLLECTION, PROP_NONE);
+	RNA_def_property_collection_sdna(prop, NULL, "markers", NULL);
+	RNA_def_property_struct_type(prop, "TimelineMarker");
+	RNA_def_property_ui_text(prop, "Timeline Markers", "Markers used in all timelines for the current scene.");
+
 	rna_def_tool_settings(brna);
 	rna_def_scene_render_data(brna);
 }

Added: branches/blender2.5/blender/source/blender/makesrna/intern/rna_timeline.c
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/intern/rna_timeline.c	                        (rev 0)
+++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_timeline.c	2009-02-24 03:06:23 UTC (rev 19096)
@@ -0,0 +1,62 @@
+/**
+ * $Id$
+ *
+ * ***** BEGIN GPL LICENSE BLOCK *****
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software Foundation,
+ * Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
+ *
+ * Contributor(s): Blender Foundation (2008), Roland Hess
+ *
+ * ***** END GPL LICENSE BLOCK *****
+ */
+
+#include <stdlib.h>
+
+#include "RNA_define.h"
+#include "RNA_types.h"
+
+#include "rna_internal.h"
+
+#include "DNA_scene_types.h"
+
+#ifdef RNA_RUNTIME
+
+#else
+
+static void rna_def_timeline_marker(BlenderRNA *brna)
+{
+	StructRNA *srna;
+	PropertyRNA *prop;
+
+	srna= RNA_def_struct(brna, "TimelineMarker", NULL);
+	RNA_def_struct_sdna(srna, "TimeMarker");
+	RNA_def_struct_ui_text(srna, "Marker", "Marker for noting points in the timeline.");
+
+	/* String values */
+	prop= RNA_def_property(srna, "name", PROP_STRING, PROP_NONE);
+	RNA_def_property_ui_text(prop, "Name", "");
+	RNA_def_struct_name_property(srna, prop);
+
+	prop= RNA_def_property(srna, "frame", PROP_INT, PROP_NONE);
+	RNA_def_property_ui_text(prop, "Frame", "The frame on which the timeline marker appears.");
+}
+
+void RNA_def_timeline_marker(BlenderRNA *brna)
+{
+	rna_def_timeline_marker(brna);
+}
+
+
+#endif


Property changes on: branches/blender2.5/blender/source/blender/makesrna/intern/rna_timeline.c
___________________________________________________________________
Name: svn:executable
   + *





More information about the Bf-blender-cvs mailing list