• issue with inserting fieldlayers in r2024

    Moved Bugs windows python 2024
    4
    0 Votes
    4 Posts
    1k Views
    M
    Hey thanks for the report, I indeed fix one issue with the InsertLayer but in your case it was another one, sadly there is no workaround for you (except the one you found). The fix will be provided in the next release. Cheers, Maxime.
  • 0 Votes
    2 Posts
    443 Views
    M
    Hi @pyxelrigger there is no real way to execute a script outside of Cinema 4D without Cinema 4D. The only option is to execute c4dpy which is a complete Cinema 4D instance run as a python interpreter. For more information about it, please read c4dpy manual. Note that you have the same limitation as a standalone Cinema 4D so you can't execute multiple c4dpy instance at the same time or they need to be in different folders. Except that note that tkinter does not come by default with Cinema 4D, so you will need to install manually and don't really officially support, so it may or may not works, but from our personal experience in the SDK team, it should work. Cheers, Maxime.
  • 0 Votes
    2 Posts
    670 Views
    ferdinandF
    Hey @ThomasB, Thank you for reaching out to us. Without your code we cannot really help you, we are not the oracle of Delphi There are many things which could go wrong in your plugin. But in general what you are doing is correct; add a dummy point object with your snap points to your cache, when you want to introduce special snapping points for your custom generator object. Snapping onto the points of the returned geometry should work out of the box (but snapping sometimes struggles a bit with deep caches). There is however only limited support for adding special snapping points, as it is not really intended to add you own snap logic in that manner. The snapping module both in Python and C++ does not allow you to implement your own snapping logic, you can just read some data. You should also keep in mind that the snapping is an older part of Cinema 4D which has its flaws. You should check if your problem also does occur when you try to snap onto the converted cache of your object (current state to object). If that is the case, you know it is not something your plugin does, but simply the fact that the snapping struggles with that specific geometry/scenario. Cheers, Ferdinand
  • 0 Votes
    3 Posts
    604 Views
    pyxelriggerP
    Thanks, buddy! It worked. To be honest, I never really understood what Message(c4d.MSG_UPDATE) was all about, and now ExecutePasses is new to me
  • 0 Votes
    8 Posts
    1k Views
    C
    @ferdinand Thank you very much! I got the min and max distances also working with your input! I used the code example from the docs to traverse through the DeformCache and it worked instantly
  • fieldlayer with variable tag

    Cinema 4D SDK windows python 2023
    2
    1
    0 Votes
    2 Posts
    427 Views
    D
    found the solution ... the corresponding type is called: FLweight
  • Create folder in Volume Builder

    Cinema 4D SDK windows python 2023
    3
    0 Votes
    3 Posts
    597 Views
    D
    hi @i_mazlov, thanks for the answer. good to know about this status / limitation. for my current case I found a solution without folders..
  • 0 Votes
    3 Posts
    954 Views
    T
    Hi Adam, thanks for the update and the workaround!
  • Clone orientation without a "Up Vector"

    Cinema 4D SDK windows c++ 2024
    8
    0 Votes
    8 Posts
    3k Views
    justinleducJ
    @ferdinand Oh wow! Thank you so much for letting me know about Keenan Crane, as I was not familiar with him. I am in awe of the exhaustive list of tools he and his lab have published. The Globally Optimal Direction Fields paper seems indeed to be exactly what I am looking for. I was also surprised to see that I had already skimmed the Youtube video of the paper back in December. Thank you so much @ferdinand for this invaluable piece of information. Time to dive in! Cheers!
  • 0 Votes
    3 Posts
    555 Views
    ferdinandF
    Hey @datamilch, Thank you for reaching out to us and answering your own question. In general we prefer it when topics do not get deleted, so that other users can benefit from a topic. You should also not be able to delete this topic anymore since more than three hours have passed since you posted and because your topic has replies. Cheers, Ferdinand
  • Start Cinema 4D, how to set Preference path

    Cinema 4D SDK windows
    6
    1
    0 Votes
    6 Posts
    1k Views
    R
    @ferdinand Understood. thank you
  • 0 Votes
    5 Posts
    1k Views
    gheyretG
    @czt_306 It looks realy cool!
  • Set value of a fieldlayer parameter

    Cinema 4D SDK windows python 2023
    3
    1
    0 Votes
    3 Posts
    569 Views
    D
    hi @ferdinand, this solved it, thanks! I suspected, that I would have to write back the data, as in many other cases. but I didn't know how exactly. As for the executable code: will do so, next time! cheers Sebastian
  • Prevent material preview update

    Cinema 4D SDK windows python 2023
    3
    0 Votes
    3 Posts
    832 Views
    D
    hi @ferdinand, thanks for the information. found a workaround, that is good enough so far. I use the 3d-gradient in texture space and transform the texture tag matrix as I need it. the change in color will not occur that often.
  • 0 Votes
    5 Posts
    807 Views
    ferdinandF
    No need to be sorry
  • 0 Votes
    3 Posts
    636 Views
    ferdinandF
    Hello @gaschka, Thank you for reaching out to us. Yes, this is an encoding issue. In general, Unicode is supported by the Python to C++ bindings, as you can see, French, German, and Turkish diacritics are all correctly transported, as well as Chinese characters. [image: 1709563393413-5bfdbc74-f638-4fd8-8df9-2b95479b233b-image.png] But all these are part of the Basic Multilingual Plane (BMP) while the emojis are part of the Supplementary Multilingual Plane (SMP) of the Unicode table. It could either be that there is something not implemented or some bits get chopped off while data is sent to the C++ layer. I don't really know, the person who is responsible for the Python bindings, @m_adam, is on vacation. I will ask him once he is back, as I too would be guessing what is happening here exactly. Cheers, Ferdinand
  • 0 Votes
    4 Posts
    1k Views
    ferdinandF
    @datamilch said in Calling BaseDocument.SetMode twice in a row leads to freezes: always had the feeling, that i could print feedback while it is running That is a misconception many users have. This is because most code usually runs very fast, so you do not realize it. Note that I also wrote Script Manager script. While it technically applies to all Python Scripting scene elements, the execution of the Python VM is there always blocking, it is much more prominent for a Script Manager script. Because there the module is only executed once and it is also okay to run scripts here which take seconds to execute. But it also applies for example to a Python Programming tag, the execution of the module is there also blocking. But because the module of a Python Programming tag is called many times - on each scene update at least once, and you are anyway in a world of hurt when your Python Programming tag module takes more than ~100 ms to run, it is not that obvious there. Syntax errors are evaluated before the VM actually runs because then the compilation of your code into byte code fails (which is then later interpreted by the VM). But the error is here also displayed only after the VM stopped (just as a RuntimeError which is raised by the VM and not by the compiler), but syntax errors prevent the VM from running your code in the first place. Cheers, Ferdinand import time def main() -> None: """Run as a Python Script Manager script to see that the execution of a scope in the Python VM is blocking. This will not print five 'A's with a stride of one second, but five 'A's after five seconds. """ for _ in range(5): print('A') time. Sleep(1) if __name__ == '__main__': main()
  • 0 Votes
    7 Posts
    2k Views
    DunhouD
    Hey @m_adam , Can we port this DataDescriptionDatabaseInterface in python in some up-coming versions? this would be handy for some converting progress, now if I want to convert data, I have to manually writhe to node id, it is worth an automatic solution and we already have this. Cheers~ DunHou