On 03/02/2013 at 04:05, xxxxxxxx wrote:
Hi ingvarai,
Originally posted by xxxxxxxx
Fo instance, where is this documented: op[c4d.NULLOBJECT_DISPLAY] and k.startswith("NULLOBJECT") ?
This is not documented anywhere, it is combining knowledge about the Python language. ;-)
The vars() function is built-in and delivers a dictionary of all attributes of the passed object. I then
compare the value of the Display attribute of the object to the current attribute and if its name starts with
NULLOBJECT, I print it out. This is because constants usually are prefixed all the same for the same object.
You can get c4d.NULLOBJECT_DISPLAY from dragging the attribute from the AM into the Script Manager
(which is stated in the Py4D Docs).
Originally posted by xxxxxxxx
I downloaded the latest C++ SDK for R14. I searched for NULLOBJECT, I searched for NULLOBJECT_DISPLAY - no match whatsoever.
I downloaded the latest Python SDK for R14. I made the same search - no match at all. Where the heck is all this tucked away? Regardless of how helpful people are, especially you, I cannot rely on the forums and helpful people to get answers.
The description symbols of Objects are mostly not documented at all, as they can be retrieved via dragging
the Attribute into the Script Manager or the Console, or by looking at the according description resource
header file.
Originally posted by xxxxxxxx
What do others do? Where do you have your knowledge from? Where can I find the information that you obviously know about? Where is NULLOBJECT_DISPLAY and tons of other constants and methods hidden?
I can program in C++ instead of Python if that helps, but since the C++ doc is not better.. does it help?
The problem is, it requires you to gain experience with the API, getting to know how Cinema works. You're an
experienced developer and expect to create awesome plugins right from the start. I've not been working with
many APIs, but after working quite while with it, my opinion is, that it is good for the It "mid level" things. Hard
to start, hard to create very complex things. It is hard to create things that were not "intended". Things that
have not been created for Cinema before in that manner, the API is not proven for, yet.
For C++, I think it is definately easier to get into Cinema's internal with Python and then go to C++.
However: Developing plugins for Cinema 4D is a complex task, the API is huge. You can not expect you
to create awesome plugins just from the start, although you are a professional programmer. This is why
we are here to help you out at the café. :slightly_smiling_face:
-N