settings from preferences dialog- Import/Export
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 14/07/2011 at 17:57, xxxxxxxx wrote:
I have been going out of my mind how to access data from the c4d preferances dialog namely the import export section and hope someone can give me an answer.
Now i can read the preferences like this for example:
bc = c4d.plugins.GetWorldPluginData(c4d.FORMAT_OBJIMPORT)
imp_normals = bc.GetBool(c4d.OBJIMPORTFILTER_IMPORTNORMALS)
print "WaveFront import normals: " , imp_normalsBut this is where the problem lies the value returned is only the inital value that is set when c4d boots. It is not the actual CURRENT value as shown in the preferance dialog and never gets updated until c4d is closed and reopened.
So my question is how do i get the CURRENT setting(s) of import/Exports filters as shown by the prefs dialog.
p.s i have also tried using c4d.GetWorldContainerInstance() and the finding the data but for import/export filters it is the same as above only the inital value is shown not the current.
i have also tried c4d.plugins.FindPlugin(c4d.FORMAT_OBJIMPORT).GetDataInstance() but this does not seem to return the data i am after- not sure what it is it actually returns but seems to be a couple of ids in the basecontainer that i have no idea what they are
Many thanks in advance
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 15/07/2011 at 00:19, xxxxxxxx wrote:
Read this in another post, but couldn't try it out yet.
Maybe you try:data = doc.GetData() print data[c4d.OBJIMPORTFILTER_IMPORTNORMALS]
Cheers,
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 15/07/2011 at 04:19, xxxxxxxx wrote:
data = doc.GetData() print data[c4d.OBJIMPORTFILTER_IMPORTNORMALS]
Thanks for the reply Nux however that does not work c4d.OBJIMPORTFILTER_IMPORTNORMALS should be a bool true/false - 0/1 but that actually returns 200000219<not sure what that is but i also tried it with a few others just to be sure it did not work for example:
c4d.OBJIMPORTFILTER_OPTIMIZE - returns none should be bool
c4d.FBXEXPORT_SAVE_NORMALS- returns none should be bool
......Any other ideas or is this just simply not possible for some reason .