Revision: 18065
          
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18065
Author:   jesterking
Date:     2008-12-26 03:02:06 +0100 (Fri, 26 Dec 2008)

Log Message:
-----------
2.5 / RNA
* assorted fixes for resolving compile warnings
* in rna_armature setting for envelope weight was bug, since it was setting 
dist instead.

Modified Paths:
--------------
    branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c
    branches/blender2.5/blender/source/blender/makesrna/intern/rna_armature.c
    branches/blender2.5/blender/source/blender/makesrna/intern/rna_brush.c
    branches/blender2.5/blender/source/blender/makesrna/intern/rna_image.c
    branches/blender2.5/blender/source/blender/makesrna/intern/rna_lamp.c
    branches/blender2.5/blender/source/blender/makesrna/intern/rna_material.c
    branches/blender2.5/blender/source/blender/makesrna/intern/rna_mesh.c
    branches/blender2.5/blender/source/blender/makesrna/intern/rna_sensor.c

Modified: branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c       
2008-12-26 01:37:05 UTC (rev 18064)
+++ branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c       
2008-12-26 02:02:06 UTC (rev 18065)
@@ -814,7 +814,7 @@
                                rna_float_print(f, fprop->hardmin); fprintf(f, 
", ");
                                rna_float_print(f, fprop->hardmax); fprintf(f, 
", ");
                                rna_float_print(f, fprop->step); fprintf(f, ", 
");
-                               rna_float_print(f, fprop->precision); 
fprintf(f, ", ");
+                               rna_int_print(f, (int)fprop->precision); 
fprintf(f, ", ");
                                rna_float_print(f, fprop->defaultvalue); 
fprintf(f, ", ");
                                if(prop->arraylength) fprintf(f, 
"rna_%s_%s_default\n", srna->identifier, prop->identifier);
                                else fprintf(f, "NULL\n");

Modified: 
branches/blender2.5/blender/source/blender/makesrna/intern/rna_armature.c
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/intern/rna_armature.c   
2008-12-26 01:37:05 UTC (rev 18064)
+++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_armature.c   
2008-12-26 02:02:06 UTC (rev 18065)
@@ -70,7 +70,7 @@
 static void rna_Armature_ghost_end_frame_set(PointerRNA *ptr, int value)
 {
        bArmature *data= (bArmature*)ptr->data;
-       CLAMP(value, data->ghostsf, MAXFRAMEF/2);
+       CLAMP(value, data->ghostsf, (int)(MAXFRAMEF/2));
        data->ghostef= value;
 }
 
@@ -84,7 +84,7 @@
 static void rna_Armature_path_end_frame_set(PointerRNA *ptr, int value)
 {
        bArmature *data= (bArmature*)ptr->data;
-       CLAMP(value, data->pathsf, MAXFRAMEF/2);
+       CLAMP(value, data->pathsf, (int)(MAXFRAMEF/2));
        data->pathef= value;
 }
 
@@ -186,23 +186,23 @@
        
        /* Number values */
                /* envelope deform settings */
-       prop= RNA_def_property(srna, "envelope_distance", PROP_INT, PROP_NONE);
-       RNA_def_property_int_sdna(prop, NULL, "dist");
-       RNA_def_property_range(prop, 0, 1000);
+       prop= RNA_def_property(srna, "envelope_distance", PROP_FLOAT, 
PROP_NONE);
+       RNA_def_property_float_sdna(prop, NULL, "dist");
+       RNA_def_property_range(prop, 0.0f, 1000.0f);
        RNA_def_property_ui_text(prop, "Envelope Deform Distance", "Bone 
deformation distance (for Envelope deform only).");
        
-       prop= RNA_def_property(srna, "envelope_weight", PROP_INT, PROP_NONE);
-       RNA_def_property_int_sdna(prop, NULL, "dist");
-       RNA_def_property_range(prop, 0, 1000);
+       prop= RNA_def_property(srna, "envelope_weight", PROP_FLOAT, PROP_NONE);
+       RNA_def_property_float_sdna(prop, NULL, "weight");
+       RNA_def_property_range(prop, 0.0f, 1000.0f);
        RNA_def_property_ui_text(prop, "Envelope Deform Weight", "Bone 
deformation weight (for Envelope deform only).");
        
-       prop= RNA_def_property(srna, "radius_head", PROP_INT, PROP_NONE);
-       RNA_def_property_int_sdna(prop, NULL, "rad_head");
+       prop= RNA_def_property(srna, "radius_head", PROP_FLOAT, PROP_NONE);
+       RNA_def_property_float_sdna(prop, NULL, "rad_head");
        //RNA_def_property_range(prop, 0, 1000);  // XXX range is 0 to lim, 
where lim= 10000.0f*MAX2(1.0, view3d->grid);
        RNA_def_property_ui_text(prop, "Envelope Radius Head", "Radius of head 
of bone (for Envelope deform only).");
        
-       prop= RNA_def_property(srna, "radius_tail", PROP_INT, PROP_NONE);
-       RNA_def_property_int_sdna(prop, NULL, "rad_tail");
+       prop= RNA_def_property(srna, "radius_tail", PROP_FLOAT, PROP_NONE);
+       RNA_def_property_float_sdna(prop, NULL, "rad_tail");
        //RNA_def_property_range(prop, 0, 1000);  // XXX range is 0 to lim, 
where lim= 10000.0f*MAX2(1.0, view3d->grid);
        RNA_def_property_ui_text(prop, "Envelope Radius Tail", "Radius of tail 
of bone (for Envelope deform only).");
        
@@ -212,13 +212,13 @@
        RNA_def_property_range(prop, 1, 32);
        RNA_def_property_ui_text(prop, "B-Bone Segments", "Number of 
subdivisions of bone (for B-Bones only).");
        
-       prop= RNA_def_property(srna, "bbone_in", PROP_INT, PROP_NONE);
-       RNA_def_property_int_sdna(prop, NULL, "ease1");
+       prop= RNA_def_property(srna, "bbone_in", PROP_FLOAT, PROP_NONE);
+       RNA_def_property_float_sdna(prop, NULL, "ease1");
        RNA_def_property_range(prop, 0.0f, 2.0f);
        RNA_def_property_ui_text(prop, "B-Bone Ease In", "Length of first 
Bezier Handle (for B-Bones only).");
        
-       prop= RNA_def_property(srna, "bbone_out", PROP_INT, PROP_NONE);
-       RNA_def_property_int_sdna(prop, NULL, "ease2");
+       prop= RNA_def_property(srna, "bbone_out", PROP_FLOAT, PROP_NONE);
+       RNA_def_property_float_sdna(prop, NULL, "ease2");
        RNA_def_property_range(prop, 0.0f, 2.0f);
        RNA_def_property_ui_text(prop, "B-Bone Ease Out", "Length of second 
Bezier Handle (for B-Bones only).");
        
@@ -230,8 +230,8 @@
        prop= RNA_def_property(srna, "tail", PROP_FLOAT, PROP_VECTOR);
        RNA_def_property_ui_text(prop, "Bone Tail Location", "In Edit Mode, the 
location of the 'head' of the bone.");
        
-       prop= RNA_def_property(srna, "roll", PROP_INT, PROP_NONE);
-       RNA_def_property_range(prop, 0, 2);
+       prop= RNA_def_property(srna, "roll", PROP_FLOAT, PROP_NONE);
+       RNA_def_property_range(prop, 0.0f, 2.0f);
        RNA_def_property_ui_text(prop, "Bone Roll", "In Edit Mode, the 'roll' 
(i.e. rotation around the bone vector, equivilant to local Y-axis rotation).");
 }
 

Modified: branches/blender2.5/blender/source/blender/makesrna/intern/rna_brush.c
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/intern/rna_brush.c      
2008-12-26 01:37:05 UTC (rev 18064)
+++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_brush.c      
2008-12-26 02:02:06 UTC (rev 18065)
@@ -81,7 +81,7 @@
        prop= RNA_def_property(srna, "color", PROP_FLOAT, PROP_COLOR);
        RNA_def_property_float_sdna(prop, NULL, "rgb");
        RNA_def_property_ui_text(prop, "Color", "");
-       RNA_def_property_ui_range(prop, 0.0f , 1.0f, 10.0f, 3.0f);
+       RNA_def_property_ui_range(prop, 0.0f , 1.0f, 10.0f, 3);
        
        prop= RNA_def_property(srna, "opacity", PROP_FLOAT, PROP_NONE);
        RNA_def_property_float_sdna(prop, NULL, "alpha");
@@ -143,7 +143,7 @@
        prop= RNA_def_property(srna, "clone_offset", PROP_FLOAT, PROP_VECTOR);
        RNA_def_property_float_sdna(prop, NULL, "clone.offset");
        RNA_def_property_ui_text(prop, "Clone Offset", "");
-       RNA_def_property_ui_range(prop, -1.0f , 1.0f, 10.0f, 3.0f);
+       RNA_def_property_ui_range(prop, -1.0f , 1.0f, 10.0f, 3);
 }
 
 void RNA_def_brush(BlenderRNA *brna)

Modified: branches/blender2.5/blender/source/blender/makesrna/intern/rna_image.c
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/intern/rna_image.c      
2008-12-26 01:37:05 UTC (rev 18064)
+++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_image.c      
2008-12-26 02:02:06 UTC (rev 18065)
@@ -194,9 +194,9 @@
        RNA_def_property_range(prop, 0, 128);
        RNA_def_property_ui_text(prop, "Animation End", "End frame of an 
animated texture.");
 
-       prop= RNA_def_property(srna, "animation_speed", PROP_FLOAT, PROP_NONE);
-       RNA_def_property_float_sdna(prop, NULL, "animspeed");
-       RNA_def_property_range(prop, 1.0f, 100.0f);
+       prop= RNA_def_property(srna, "animation_speed", PROP_INT, PROP_NONE);
+       RNA_def_property_int_sdna(prop, NULL, "animspeed");
+       RNA_def_property_range(prop, 1, 100);
        RNA_def_property_ui_text(prop, "Animation Speed", "Speed of the 
animation in frames per second.");
 
        prop= RNA_def_property(srna, "tiles", PROP_BOOLEAN, PROP_NONE);

Modified: branches/blender2.5/blender/source/blender/makesrna/intern/rna_lamp.c
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/intern/rna_lamp.c       
2008-12-26 01:37:05 UTC (rev 18064)
+++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_lamp.c       
2008-12-26 02:02:06 UTC (rev 18065)
@@ -306,13 +306,13 @@
        RNA_def_property_float_sdna(prop, NULL, "r");
        RNA_def_property_array(prop, 3);
        RNA_def_property_ui_text(prop, "Color", "");
-       RNA_def_property_ui_range(prop, 0.0f, 1.0f, 10.0f, 3.0f);
+       RNA_def_property_ui_range(prop, 0.0f, 1.0f, 10.0f, 3);
 
        prop= RNA_def_property(srna, "shadow_color", PROP_FLOAT, PROP_COLOR);
        RNA_def_property_float_sdna(prop, NULL, "shdwr");
        RNA_def_property_array(prop, 3);
        RNA_def_property_ui_text(prop, "Shadow Color", "");
-       RNA_def_property_ui_range(prop, 0.0f, 1.0f, 10.0f, 3.0f);
+       RNA_def_property_ui_range(prop, 0.0f, 1.0f, 10.0f, 3);
 
        /* Booleans */
        prop= RNA_def_property(srna, "auto_clip_start", PROP_BOOLEAN, 
PROP_NONE);

Modified: 
branches/blender2.5/blender/source/blender/makesrna/intern/rna_material.c
===================================================================
--- branches/blender2.5/blender/source/blender/makesrna/intern/rna_material.c   
2008-12-26 01:37:05 UTC (rev 18064)
+++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_material.c   
2008-12-26 02:02:06 UTC (rev 18065)
@@ -159,9 +159,9 @@
        RNA_def_property_range(prop, 0.0f, 1.0f);
        RNA_def_property_ui_text(prop, "Ray Mirror Gloss Aniso", "The shape of 
the reflection, from 0.0 (circular) to 1.0 (fully stretched along the 
tangent.");
                
-       prop= RNA_def_property(srna, "ray_mirror_gloss_samples", PROP_FLOAT, 
PROP_NONE);
-       RNA_def_property_float_sdna(prop, NULL, "samp_gloss_mir");
-       RNA_def_property_range(prop, 0.0f, 1024.0f);
+       prop= RNA_def_property(srna, "ray_mirror_gloss_samples", PROP_INT, 
PROP_NONE);
+       RNA_def_property_int_sdna(prop, NULL, "samp_gloss_mir");
+       RNA_def_property_range(prop, 0, 1024);
        RNA_def_property_ui_text(prop, "Ray Mirror Gloss Samples", "Number of 
cone samples averaged for blurry reflections.");
        
        prop= RNA_def_property(srna, "ray_mirror_adapt_thresh", PROP_FLOAT, 
PROP_NONE);
@@ -211,9 +211,9 @@
        RNA_def_property_range(prop, 0.0f, 1.0f);
        RNA_def_property_ui_text(prop, "Ray Transparency Gloss", "The clarity 
of the refraction. Values < 1.0 give diffuse, blurry refractions.");
        
-       prop= RNA_def_property(srna, "ray_transparency_gloss_samples", 
PROP_FLOAT, PROP_NONE);
-       RNA_def_property_float_sdna(prop, NULL, "samp_gloss_tra");
-       RNA_def_property_range(prop, 0.0f, 1024.0f);
+       prop= RNA_def_property(srna, "ray_transparency_gloss_samples", 
PROP_INT, PROP_NONE);
+       RNA_def_property_int_sdna(prop, NULL, "samp_gloss_tra");
+       RNA_def_property_range(prop, 0, 1024);
        RNA_def_property_ui_text(prop, "Ray Transparency Gloss Samples", 
"Number of cone samples averaged for blurry refractions.");
        

@@ Diff output truncated at 10240 characters. @@

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to