<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Python FBXSDK FbxProperty.Get() not exported to Py? Critical issue in FBX Forum</title>
    <link>https://forums.autodesk.com/t5/fbx-forum/python-fbxsdk-fbxproperty-get-not-exported-to-py-critical-issue/m-p/11531381#M249</link>
    <description>&lt;P&gt;In your example p1 is a fbx.FbxProperty object, you need to convert it to a concrete property type (ie a subclass of FbxProperty) before calling Get.&lt;/P&gt;&lt;P&gt;eg&lt;/P&gt;&lt;LI-CODE lang="general"&gt;import fbx
manager = fbx.FbxManager.Create()
scene = fbx.FbxScene.Create(manager, "scene")
model = fbx.FbxNull.Create(scene, "myModel")
p1 = fbx.FbxProperty.Create(model, fbx.FbxGetDataTypeFromEnum(fbx.eFbxBool), "MyBooleanProperty", "My Bool")
p1.Set(True)

value = p1.Get()  # AttributeError: 'FbxProperty' object has no attribute 'Get'

asert fbx.FbxPropertyBool1(p1).Get() == True  # cast property, then get
assert fbx.FbxPropertyString(p1).Get() == "true"  # cast to other types etc&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It's convenient in Python to just have a mapping of EFbxType enums to the typed FbxProperty subclass.&lt;/P&gt;&lt;LI-CODE lang="general"&gt;datatype_map = {
    fbx.eFbxBool: fbx.FbxPropertyBool1,
    ...  # etc
    fbx.eFbxString: fbx.FbxPropertyString,
}
enum_type = prop.GetPropertyDataType().GetType()  # eg fbx.eFbxBool
typed_prop = datatype_map[enum_type](prop)

typed_prop.Get()  # etc&lt;/LI-CODE&gt;</description>
    <pubDate>Fri, 04 Nov 2022 15:39:44 GMT</pubDate>
    <dc:creator>ross-g</dc:creator>
    <dc:date>2022-11-04T15:39:44Z</dc:date>
    <item>
      <title>Python FBXSDK FbxProperty.Get() not exported to Py? Critical issue</title>
      <link>https://forums.autodesk.com/t5/fbx-forum/python-fbxsdk-fbxproperty-get-not-exported-to-py-critical-issue/m-p/11525025#M248</link>
      <description>&lt;P&gt;Python FBX SDK - ver currently latest 202032:&lt;BR /&gt;I can't access (static) value of the property with Get() - it seems FbxProperty class doesn't have Get() exposed (on the other hand, Set() is exposed properly).&lt;BR /&gt;Try this trivial code:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;import fbx&lt;/P&gt;&lt;P&gt;manager=fbx.FbxManager.Create()&lt;/P&gt;&lt;P&gt;scene=fbx.FbxScene.Create(manager,"scene")&lt;/P&gt;&lt;P&gt;model=fbx.FbxNull.Create(scene,"myModel")&lt;BR /&gt;p1 = fbx.FbxProperty.Create(model, fbx.FbxBoolDT, "MyBooleanProperty", "My Bool")&lt;BR /&gt;p1.Set(True)&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; #this works fine and FBX loaded to MoBuilder does have the property and it is set True.&lt;BR /&gt;value=p1.Get() #this fails&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Get() in C++ is documented here:&lt;BR /&gt;&lt;A href="https://help.autodesk.com/cloudhelp/2020/ENU/FBX-Developer-Help/cpp_ref/class_fbx_property.html#a6b9edba314158f58b259fc8c37f1d7f7" target="_blank"&gt;https://help.autodesk.com/cloudhelp/2020/ENU/FBX-Developer-Help/cpp_ref/class_fbx_property.html#a6b9edba314158f58b259fc8c37f1d7f7&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;confusing is, that getting values of built in properties, such as skeletonJointAttribute.Size.Get() actually DOES work fine, however .Size, .Color etc. appear as object one of subclasses of FbxProperty, not the FbxProperty itself... however any property found by name or created as shown above fails to get data back.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I consider this really fatal omission - FBX scenes are built on properties, both user and default, and when the property isn't animated, it is impossible to retrieve its value at the moment - unless I do something wrong.&lt;BR /&gt;&lt;BR /&gt;Any help appreciated!&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Kind regards,&lt;/P&gt;&lt;P&gt;Stepan&lt;/P&gt;</description>
      <pubDate>Wed, 02 Nov 2022 10:33:52 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fbx-forum/python-fbxsdk-fbxproperty-get-not-exported-to-py-critical-issue/m-p/11525025#M248</guid>
      <dc:creator>stepan.kment7WW22</dc:creator>
      <dc:date>2022-11-02T10:33:52Z</dc:date>
    </item>
    <item>
      <title>Re: Python FBXSDK FbxProperty.Get() not exported to Py? Critical issue</title>
      <link>https://forums.autodesk.com/t5/fbx-forum/python-fbxsdk-fbxproperty-get-not-exported-to-py-critical-issue/m-p/11531381#M249</link>
      <description>&lt;P&gt;In your example p1 is a fbx.FbxProperty object, you need to convert it to a concrete property type (ie a subclass of FbxProperty) before calling Get.&lt;/P&gt;&lt;P&gt;eg&lt;/P&gt;&lt;LI-CODE lang="general"&gt;import fbx
manager = fbx.FbxManager.Create()
scene = fbx.FbxScene.Create(manager, "scene")
model = fbx.FbxNull.Create(scene, "myModel")
p1 = fbx.FbxProperty.Create(model, fbx.FbxGetDataTypeFromEnum(fbx.eFbxBool), "MyBooleanProperty", "My Bool")
p1.Set(True)

value = p1.Get()  # AttributeError: 'FbxProperty' object has no attribute 'Get'

asert fbx.FbxPropertyBool1(p1).Get() == True  # cast property, then get
assert fbx.FbxPropertyString(p1).Get() == "true"  # cast to other types etc&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It's convenient in Python to just have a mapping of EFbxType enums to the typed FbxProperty subclass.&lt;/P&gt;&lt;LI-CODE lang="general"&gt;datatype_map = {
    fbx.eFbxBool: fbx.FbxPropertyBool1,
    ...  # etc
    fbx.eFbxString: fbx.FbxPropertyString,
}
enum_type = prop.GetPropertyDataType().GetType()  # eg fbx.eFbxBool
typed_prop = datatype_map[enum_type](prop)

typed_prop.Get()  # etc&lt;/LI-CODE&gt;</description>
      <pubDate>Fri, 04 Nov 2022 15:39:44 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fbx-forum/python-fbxsdk-fbxproperty-get-not-exported-to-py-critical-issue/m-p/11531381#M249</guid>
      <dc:creator>ross-g</dc:creator>
      <dc:date>2022-11-04T15:39:44Z</dc:date>
    </item>
    <item>
      <title>Re: Python FBXSDK FbxProperty.Get() not exported to Py? Critical issue</title>
      <link>https://forums.autodesk.com/t5/fbx-forum/python-fbxsdk-fbxproperty-get-not-exported-to-py-critical-issue/m-p/11544034#M250</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thank You so much! Really helpful and I do confirm this solves the problem.&lt;BR /&gt;&lt;BR /&gt;Outstanding question is actuall correct class of the given property for its eType: I managed to match some of them, but not all by far (Nones in the picture) - a matter of fact is in motionBuilder, there are items in the property type enum that aren't found in moBu, such as this Uint, short floats, longlong etc.. hopefully, I'll be fine anyway.&lt;BR /&gt;&lt;BR /&gt;Again, thank You for valuable guidance!&lt;BR /&gt;Stepan&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="stepankment7WW22_0-1668095219629.png" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1138335iBA6299A647C32D9C/image-size/medium?v=v2&amp;amp;px=400" role="button" title="stepankment7WW22_0-1668095219629.png" alt="stepankment7WW22_0-1668095219629.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 10 Nov 2022 15:49:02 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fbx-forum/python-fbxsdk-fbxproperty-get-not-exported-to-py-critical-issue/m-p/11544034#M250</guid>
      <dc:creator>stepan.kment7WW22</dc:creator>
      <dc:date>2022-11-10T15:49:02Z</dc:date>
    </item>
    <item>
      <title>Re: Python FBXSDK FbxProperty.Get() not exported to Py? Critical issue</title>
      <link>https://forums.autodesk.com/t5/fbx-forum/python-fbxsdk-fbxproperty-get-not-exported-to-py-critical-issue/m-p/11545721#M251</link>
      <description>&lt;P&gt;so one thing I couldn't get to work is reference type property in MoBuilder - the property that holds a reference to a scene object. There is fbx.FbxReference class this property can be cast to, however the object doesn't expose any meaningful methods to retrieve the node referenced by the property, likely this isn't the right class. There is a fbx scene reference object, however that (imho) serves different purpose, inserts a referenced FBX scene into the main scene. Any idea here, please?&lt;BR /&gt;-----&lt;BR /&gt;Aside of that, I confirm RGB, RGBA, float, int, enum (including list of options), bool, vectors all do work fine; didn't test time nor timecode.&lt;BR /&gt;&lt;BR /&gt;Thank You,&lt;BR /&gt;Stepan&lt;/P&gt;</description>
      <pubDate>Fri, 11 Nov 2022 09:20:47 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fbx-forum/python-fbxsdk-fbxproperty-get-not-exported-to-py-critical-issue/m-p/11545721#M251</guid>
      <dc:creator>stepan.kment7WW22</dc:creator>
      <dc:date>2022-11-11T09:20:47Z</dc:date>
    </item>
  </channel>
</rss>

