• CommandData plugin catch Switching documents event

    Cinema 4D SDK python r23
    3
    0 Votes
    3 Posts
    426 Views
    mikeudinM
    @ferdinand Thank you!
  • Importing RSproxies using Python

    Cinema 4D SDK s26 python
    5
    2
    0 Votes
    5 Posts
    1k Views
    UMDU
    Oh I see.. The ExecutePasses was the key ! Thank you for your answers !
  • Create Polygon Selection Tag

    Cinema 4D SDK python
    5
    0 Votes
    5 Posts
    1k Views
    D
    @ferdinand aaaa i understood, thanks for help megaman)
  • Is there a fixed Manager ID like c4d.CONSTANT?

    Cinema 4D SDK python
    2
    2
    0 Votes
    2 Posts
    297 Views
    ManuelM
    Hi, Those IDs should not change but there are not guaranties. There are no symbols to define those IDs. You can use the following code to displays all the registered Managers. import c4d from c4d import gui def main(): pluginList = c4d.plugins.FilterPluginList(c4d.PLUGINTYPE_MANAGERINFORMATION, True) for plugin in pluginList: print (plugin, plugin.GetID()) # Execute main() if __name__=='__main__': main() Cheers, Manuel
  • How to Create and Populate a Layer Shader?

    Cinema 4D SDK python
    3
    0 Votes
    3 Posts
    2k Views
    indexofrefractionI
    @ferdinand hey ferdinand , thanks for all of this information ! i also noticed that definitions are missing in the python SDK (specifically the BlendModes)
  • Copy LayerShader to a new Material

    Cinema 4D SDK python
    11
    0 Votes
    11 Posts
    2k Views
    indexofrefractionI
    tx ferdinand, and yes intertwined threads .-)
  • 0 Votes
    3 Posts
    630 Views
    ferdinandF
    Hello @cinamatic, without any further questions or other postings, we will consider this topic as solved and flag it as such by Friday, 17/06/2022. Thank you for your understanding, Ferdinand
  • What is my Clipboardowner for a script?

    Cinema 4D SDK c++ python
    4
    0 Votes
    4 Posts
    756 Views
    ferdinandF
    Hey @cairyn, yeah, you are right. @m_adam already pointed this out too. I screwed up and overwrote my clipboard when I tried this out. I have edited my initial posting, to not confuse future readers. GetC4DClipboardOwner works fine in regards to the Picture Viewer and Bodypaint, but the argument ownerid of CopyBitmapToClipboard is effectively meaningless in the public API, as it lacks the window handle context to actually cause the ownerid to be stored. The owner id will always be set to 0. And to underline the answer to your major question: It seems very unlikely that you could crash Cinema 4D with writing a made-up owner id into the clipboard (in the case the function would work properly and actually store the id). It is hard to give here absolute answers, as there is a lot of code in our code base. In the context of the clipboard alone, crashing can be excluded, but there could be other parts of Cinema 4D which make assumptions based on the owner id. Which is why I would recommend not using the predefined ones (which is rather theoretical due to said limitations of CopyBitmapToClipboard). Cheers, Ferdinand
  • Modul import

    Cinema 4D SDK r21 python
    3
    0 Votes
    3 Posts
    699 Views
    W
    Thank you very much!
  • Touch input objects withot resetting its cache

    Cinema 4D SDK python
    6
    0 Votes
    6 Posts
    984 Views
    ferdinandF
    Hey @baca, as I said, the control object structure you want is not possible. I tried and wrote the necessary code when I answered here initially, and Cinema 4D will really start to freak out. You cannot have nested hierarchies of muted caches. If you really want to do this, then you must use the approach proposed by me. If you want to also hide the objects in renderings, then you will have to also set that parameter. If you poke around long enough, you might find a solution by muting the caches, but this is out of scope of support. As I said, I did already try when I wrote my first posting, maybe you have more luck. But as also stated in my first posting, you are poking here the sleeping bear called "classic API node dependencies". Cheers, Ferdinand
  • 1 Votes
    3 Posts
    752 Views
    L
    @m_adam Thanks so much! You are a very professional guy!!!
  • Getting Current Render Frame

    Cinema 4D SDK
    6
    0 Votes
    6 Posts
    1k Views
    M
    Sorry for the late reply In order to do that you will need to start a new thread, and you need to keep alive the thread as long as it execute, meaning you will need to store it in a global variable. Best way would be to reach octane directly as 3rd party are free to implement this as they want. Cheers, Maxime.
  • 0 Votes
    3 Posts
    572 Views
    ferdinandF
    Hello @LingZA, without any further questions or other postings, we will consider this topic as solved and flag it as such by Friday, 17/06/2022. Thank you for your understanding, Ferdinand
  • How to know is DescID is "takeble"?

    Cinema 4D SDK python
    3
    0 Votes
    3 Posts
    314 Views
    mikeudinM
    @m_magalhaes Thank you!
  • 0 Votes
    4 Posts
    620 Views
    ferdinandF
    Hello @lingza, well as lined out, you cannot implement a VertexmMapTag which is the same as a normal VertexMapTag but has extra parameters to realize your desired functionality. You can solve this problem with either the pattern I described under point 3 in my last posting, or by implementing a ToolData plugin which simply generates the tag. The solution using a driver tag has the advantage that the user can continuously tweak the output of the vertexmap, while a tool must be picked up again. Actually, I mean that I want to create a tag which contains the vertex weights, then vertex weights are used by ZRemesher after I put the tag into Density Map linkbox. So I don't need a "vertex map" indeed, but I need a tag I describe above. This is unfortunately not true. You will need a vertex map tag, as this parameter, the Density Map parameter, will accept only a VertexMapTag. It will not know what to do with a CustomDataTag . I would recommend having a look at the project file I have posted above, it contains a practical example for the pattern of a tag driving a vertex map. Cheers, Ferdinand
  • Context Problem

    Cinema 4D SDK python r21
    7
    0 Votes
    7 Posts
    1k Views
    ferdinandF
    Thanks for the update!
  • How to make a Python Plugin...

    Cinema 4D SDK python
    5
    1 Votes
    5 Posts
    2k Views
    mikeudinM
    @noseman seems that it's needs to be updated https://github.com/nrosenstein-c4d/c4d-prototype-converter/issues/52
  • 0 Votes
    3 Posts
    570 Views
    L
    Thanks so much!!! Your answer makes me understand that PolygonObject.GetPolygonS(self) and PolygonObject.GetPolygonH(self) respectively represent selection states in a list from BaseSelect and visibility states in a list from BaseSelect.
  • Draw editable spline in the viewport

    Cinema 4D SDK python
    5
    0 Votes
    5 Posts
    1k Views
    bacaB
    @ferdinand thanks for explanations and example.
  • Python writing to desktop

    Moved General Talk python r25
    4
    0 Votes
    4 Posts
    993 Views
    ferdinandF
    Hello @Peek, without any further questions or other postings, we will consider this topic as solved and flag it as such by Friday, 17/06/2022. Thank you for your understanding, Ferdinand