Revision: 38870
          
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=38870
Author:   phabtar
Date:     2011-07-31 05:04:12 +0000 (Sun, 31 Jul 2011)
Log Message:
-----------
Camera Clipping animation COLLADA support fix.

Modified Paths:
--------------
    branches/soc-2011-pepper/source/blender/collada/AnimationExporter.cpp
    branches/soc-2011-pepper/source/blender/collada/AnimationImporter.cpp
    branches/soc-2011-pepper/source/blender/collada/AnimationImporter.h

Modified: branches/soc-2011-pepper/source/blender/collada/AnimationExporter.cpp
===================================================================
--- branches/soc-2011-pepper/source/blender/collada/AnimationExporter.cpp       
2011-07-31 03:15:37 UTC (rev 38869)
+++ branches/soc-2011-pepper/source/blender/collada/AnimationExporter.cpp       
2011-07-31 05:04:12 UTC (rev 38870)
@@ -94,7 +94,7 @@
                                
                                if ((!strcmp(transformName, "lens"))||
                                        (!strcmp(transformName, 
"ortho_scale"))||
-                                       (!strcmp(transformName, 
"clipend"))||(!strcmp(transformName, "clipsta"))) 
+                                       (!strcmp(transformName, 
"clip_end"))||(!strcmp(transformName, "clip_start"))) 
                                        dae_animation(ob , fcu, transformName, 
true );
                                fcu = fcu->next;
                        }
@@ -836,9 +836,9 @@
                                tm_type = 7;
             else if (!strcmp(name, "ortho_scale"))
                                tm_type = 8;
-                       else if (!strcmp(name, "clipend"))
+                       else if (!strcmp(name, "clip_end"))
                                tm_type = 9;
-                       else if (!strcmp(name, "clipsta"))
+                       else if (!strcmp(name, "clip_start"))
                                tm_type = 10;
                        else if (!strcmp(name, "specular_hardness"))
                                tm_type = 11;

Modified: branches/soc-2011-pepper/source/blender/collada/AnimationImporter.cpp
===================================================================
--- branches/soc-2011-pepper/source/blender/collada/AnimationImporter.cpp       
2011-07-31 03:15:37 UTC (rev 38869)
+++ branches/soc-2011-pepper/source/blender/collada/AnimationImporter.cpp       
2011-07-31 05:04:12 UTC (rev 38870)
@@ -896,14 +896,14 @@
                        {
                                const COLLADAFW::AnimatableFloat *zfar =  
&(camera->getFarClippingPlane());
                                const COLLADAFW::UniqueId& listid = 
zfar->getAnimationList();
-                               Assign_float_animations( listid ,AnimCurves, 
"clipend"); 
+                               Assign_float_animations( listid ,AnimCurves, 
"clip_end"); 
                        }
 
                        if ((animType->camera & CAMERA_ZNEAR) != 0 )
                        {
                                const COLLADAFW::AnimatableFloat *znear =  
&(camera->getNearClippingPlane());
                                const COLLADAFW::UniqueId& listid = 
znear->getAnimationList();
-                               Assign_float_animations( listid ,AnimCurves, 
"clipsta"); 
+                               Assign_float_animations( listid ,AnimCurves, 
"clip_start"); 
                        }
 
                }
@@ -1009,7 +1009,7 @@
                        types->material =  
setAnimType(&(efc->getShininess()),(types->material), MATERIAL_SHININESS);
                        types->material =  
setAnimType(&(efc->getSpecular().getColor()),(types->material), 
MATERIAL_SPEC_COLOR);
                        types->material =  
setAnimType(&(efc->getDiffuse().getColor()),(types->material), 
MATERIAL_DIFF_COLOR);
-               
+                  // types->material =  
setAnimType(&(efc->get()),(types->material), MATERIAL_TRANSPARENCY);
                }
        }
        return types;

Modified: branches/soc-2011-pepper/source/blender/collada/AnimationImporter.h
===================================================================
--- branches/soc-2011-pepper/source/blender/collada/AnimationImporter.h 
2011-07-31 03:15:37 UTC (rev 38869)
+++ branches/soc-2011-pepper/source/blender/collada/AnimationImporter.h 
2011-07-31 05:04:12 UTC (rev 38870)
@@ -110,7 +110,8 @@
        {
                MATERIAL_SHININESS = 2,
                MATERIAL_SPEC_COLOR = 4,
-               MATERIAL_DIFF_COLOR = 1 << 3
+               MATERIAL_DIFF_COLOR = 1 << 3,
+               MATERIAL_TRANSPARENCY = 1 << 4
        };
        
        enum AnimationType

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

Reply via email to