Well, of course I figure it out 3 minutes after I sent the question.
castProperty.Get()[0] gives me the first of the three values. Problem
solved.
On Mon, Aug 25, 2014 at 4:26 PM, Christian Gotzinger
wrote:
> Hi list,
>
> Does anybody have some experience with the FBX SDK? I'm writing an
> external Python application to analyze FBX files.
> Everything has worked well so far, but here's where I'm stuck: I need to
> read shader information, such as diffuse color or specular color.
>
> The core code inside my loop looks like this:
> prop_new = node.GetNextProperty(prop)
> if prop_new.GetName() == "DiffuseColor":
> castProperty = fbx.FbxPropertyDouble3(prop_new)
>
> But now I can't figure out how to extract the three float values from
> castProperty.
> print castProperty.Get() tells me ""
> print castProperty.Get().mData[0] tells me "FbxDouble3 object has no
> attribute mdata"
>
> Maybe I'm unable to read the documentation correctly.
> FbxProperty:
>
> http://docs.autodesk.com/FBX/2014/ENU/FBX-SDK-Documentation/index.html?url=cpp_ref/class_fbx_property.html,topicNumber=cpp_ref_class_fbx_property_htmlb0f98359-b7ce-427b-b82e-dff4d47ce167
>
> FbxVectorTemplate3:
>
> http://docs.autodesk.com/FBX/2014/ENU/FBX-SDK-Documentation/index.html?url=cpp_ref/class_fbx_vector_template3.html,topicNumber=cpp_ref_class_fbx_vector_template3_htmle8f366ab-3383-4598-9d16-4a44516cf62d
>