The Maxon SDK Team is currently short staffed due to the winter holidays. No forum support is being provided between 15/12/2025 and 5/1/2026. For details see Maxon SDK 2025 Winter Holidays.
  • Animated viewport preview in Node Materials

    c++
    6
    1
    1 Votes
    6 Posts
    2k Views
    P
    Hey Ferdinand, Thank you for investigating and digging deep on the topic, much appreciated. I'll handle this as a limitation for now, until an official solution exists. But don't worry, it's not a high priority for us at the moment. Thank you, Peter
  • Calling “Add” button in Multi Shader: doesn’t work!

    r25 python 2024
    7
    0 Votes
    7 Posts
    1k Views
    S
    Yes, I know about not using multiple events. I was playing with that, I thought that's the reason the button was not being called Thank you @ferdinand
  • TagData plugin undo issues

    python windows
    6
    0 Votes
    6 Posts
    1k Views
    ferdinandF
    No need to be sorry, a good to hear that you found your solution!
  • How to set the "Texture preview size" value on a new material?

    c++ windows 2024
    3
    0 Votes
    3 Posts
    847 Views
    sasha_janvierS
    Once again, I am immensely grateful for your generous and incredibly helpful assistance, @ferdinand ! I don’t know why I didn’t mention SetParameter() in my original message, as this was the first thing I attempted before experimenting with the other methods I mentioned. Thank you once again. I was able to throughly familiarize myself with GetParameter() and SetParameter() today.
  • 0 Votes
    3 Posts
    951 Views
    ThomasBT
    @ferdinand Thanks a lot Ferdinand for your time and effort. It is always admirable how carefully and thoroughly you answer many questions. At first it was often difficult to understand and follow your code examples...now it is a little easier. Thanks for that. I found out that the following method also does the job: c4d.SendCoreMessage(c4d.COREMSG_CINEMA, c4d.BaseContainer(c4d.COREMSG_CINEMA_FORCE_AM_UPDATE), 0) Sorry for the second question about why this buttonDesc[c4d.DESC_FITH] = True buttonDesc[c4d.DESC_SCALEH] = True in the GetDDescription method are not working. I thought this is a follow-up question. I will open another topic for that.
  • Can I get the plugin(Command) help string in other C4DThread?

    windows python 2024
    4
    0 Votes
    4 Posts
    654 Views
    ferdinandF
    Hey everyone, just to add a little disclaimer here, as Maxime gave a very hacking friendly answer with the a bit tame warning 'do it at your own risk'. What you are tyring to do is out of scope of support because it is a violation of the threading restrictions. The whole core message system is about events and UI, both things that are inherently bound to the main thread. Maxime's code just circumvents the main-thread check someone once put into our code for a reason, as that person also made sure to put a warning into the docs. When you are someone like Maxime, i.e., you know all the bits and bytes of Cinema 4D on a first-name basis, you can make a workaround like this work. But for everyone else I would strongly recommend not circumventing such things in production code. Just because a hack runs fine on a development machine, does not mean that a customer might not lose work due to a crash induced by such hack. The underlying issue we talked about this morning, is that in C++ one can easily defer things to the main thread with the aptly named ExecuteOnMaainThread while in Python one cannot. We are aware of this issue but it is quite costly to solve. An outcome of this thread, was that we at least promoted the priority of the already existing ticket for this issue in our task pool. We can however give no ETA when we will fix this, as doing this will cost quite some time. Cheers, Ferdinand
  • Is that possible to get current active subwindow of C4D?

    windows python 2024
    3
    0 Votes
    3 Posts
    759 Views
    gheyretG
    Thanks for your explanation @m_adam , Yes it's a CommandData plguin but no GeDialog. Because of some limitations, I had to use PySide to create my plugin's special user interface.
  • BaseDraw.DrawHUDText in Cinema4D 2024

    2024 python
    6
    0 Votes
    6 Posts
    1k Views
    ferdinandF
    Hello @FlavioDiniz, thank you for reaching out to us. No, that was not fixed in 2024.4. The current plan is to fix it an upcoming minor release, but as always we cannot give any guarantees regarding an ETA. There are currently no workarounds for the other issue. Cheers, Ferdinand
  • Is that possibe to Hide Object in Active BaseDraw?

    python 2024 windows
    3
    0 Votes
    3 Posts
    528 Views
    gheyretG
    Hi @ferdinand, Thanks for your reply. I just want to make sure if it's possible. And I'll try the BaseDraw.DrawObject later.
  • 0 Votes
    14 Posts
    3k Views
    ferdinandF
    Hey @bojidar, So, I spent again some time on trying to debug this, and this time manually stepped through the deserialization of 1053286, i.e., your material type. And I am not really any wiser to what is going wrong there. This could be related to a change one of developers made for 2024 to GeAliasGoal, a precursor to what you see as a BaseLink in the public API. But when I look at how it steps through the chunks of the hyper file for your material, I do not really ever see that parameter being deserialized. I think this is more a Tech team than an SDK team issue as they own that part of our APIs. I would have to ask you to file a bug report via our bug tracker for this. Please make sure to include: Reproduction steps. The file. You can also include your code, but that is of less importance. Please give me then also a note when you have done this, so that I can attach the relevant people and make sure that they get access to a license of your software. I could also file the bug report for you, the problem would be then however, that you could not see it, as you can only see your own reports as an MRD. I.e., you could not take part in the comments/discussion attached to the issue. I would recommend that you submit it yourself. When you run into problems, ask Deyan, or reach out to us via mail. Cheers, Ferdinand
  • How to add parameter groups to Nodes dynamically?

    c++
    5
    0 Votes
    5 Posts
    896 Views
    P
    Thank you for taking time on this. Definitely promising. I'll give it a spin to see if I can reach the desired results with any of the mentioned approaches.
  • How to generate a tag?

    python 2024
    3
    0 Votes
    3 Posts
    615 Views
    F
    Ok thanks. Will do that!
  • 0 Votes
    4 Posts
    663 Views
    i_mazlovI
    Hello @Hongzz, Welcome to the Maxon developers forum and its community, it is great to have you with us! Getting Started Before creating your next postings, we would recommend making yourself accustomed with our forum and support procedures. You did not do anything wrong, we point all new users to these rules. Forum Overview: Provides a broad overview of the fundamental structure and rules of this forum, such as the purpose of the different sub-forums or the fact that we will ban users who engage in hate speech or harassment. Support Procedures: Provides a more in detail overview of how we provide technical support for APIs here. This topic will tell you how to ask good questions and limits of our technical support. Forum Features: Provides an overview of the technical features of this forum, such as Markdown markup or file uploads. It is strongly recommended to read the first two topics carefully, especially the section Support Procedures: Asking Questions. About your First Question When removing all the path handling fluff from your code, everything works as expected (the layout is created properly, when runs from both "Execute" button and the menu item). Please check the attached script below. This actually means that there's something fishy going on with the files on your filesystem or the way you're dealing with them. I'd suggest improve handling edge cases, when the path doesn't exist or when there're no files in the specified path. There're a couple more comments on your posting. First of all, storing your dialog in the global scope of the script is a "hack" that is a) highly not recommended in general b) exceptionally not recommended for being shipped to the end user. You should consider developing a plugin instead, if you need your dialog to be persistent over multiple openings of your dialog. You can have a look into our github repository for some references, e.g. the CommandDataDialog example. Secondly, please consolidate your consequent messages in a single posting as it improves the readabily of the forum (please check the "Support Topic Rules" part of our Support Procedures). For your previous message I've already done this for you. Cheers, Ilia The code snippet without unnecessary path handling parts: import os import c4d class ImportDialog(c4d.gui.GeDialog): BUTTON_ID_BASE = 1000 def __init__(self): self.files = ['myFile1.c4d', 'myFile2.c4d', 'myFile3.c4d'] def CreateLayout(self): self.SetTitle("Import C4D Projects") for index, file in enumerate(self.files, start=self.BUTTON_ID_BASE): filename = os.path.splitext(os.path.basename(file))[0] self.AddButton(index, c4d.BFH_CENTER, name=filename) return True global_dialog_instance = None def main(): global global_dialog_instance if global_dialog_instance is None: global_dialog_instance = ImportDialog() global_dialog_instance.Open(c4d.DLG_TYPE_ASYNC, defaultw=400, defaulth=50) if __name__=="__main__": main()
  • Drag Object in GeDialog.AddEditText

    windows 2024 python
    4
    0 Votes
    4 Posts
    743 Views
    ferdinandF
    Hey @pyxelrigger, sure you can use the string custom GUI. You could also use a base link or a filename field which be the more natural solutions for this. But you asked for AddEditText and that is what I answered. Cheers, Ferdinand
  • Post build event settings on windows and mac

    c++ windows macos
    3
    0 Votes
    3 Posts
    696 Views
    B
    Thank you, @ferdinand
  • How to store BaseShader to HyperFile

    windows python 2024
    7
    0 Votes
    7 Posts
    1k Views
    gheyretG
    Hi @ferdinand , Yeah! I'm actually considering saving the shader to .c4d file as well. But it would be great if posible to store BaseList2D in Hyperfile. Thank you! Cheers!
  • How to access the "root" Scene Nodes graph

    python 2024
    3
    0 Votes
    3 Posts
    610 Views
    K
    Hi @ferdinand , Thanks as always for your clear answers, It solved the problem for me!
  • UuidInterface.ToString() raise a TypeError.

    windows python 2024
    3
    0 Votes
    3 Posts
    559 Views
    DunhouD
    Wow @ferdinand! What a super detailed and super useful information ! Always learning great things from your super user-friendly answers for rookies like me Memory Management is very useful to understand what happened here, I will read it again tomorrow after work, hope I can have a deeper understanding then About the Interfaces/References/Ref class name, super useful information, I always confused them and thought it was an inheritance relationship or something like that, it is much cleaner now! Thanks for your typing tips here, I had learn this by testing your answers and codes (In fact, most of my programming skills are learned through studying your code, and I am truly grateful to you) Last, thanks or your times during the meeting time! Cheers~ DunHou
  • FBX does not export

    windows 2024 python
    2
    0 Votes
    2 Posts
    454 Views
    ferdinandF
    Hey @pyxelrigger, Thank you for reaching out to us. It is always difficult for me in these cases to find the right words. Generally speaking, what you ask us to do here, is out of scope of support: Either debug your code or finish the script for you. What I see here is primarily a user who is overwhelmed by his or her own code. Especially when you are less experienced: Just break up things into manageable pieces where you know what they do and you can confirm that they do what you mean them to do. And when I run into troubles, the first thing I would also remove is all UI fluff. You could for example define your paths just at the top of the script. Finally, NEVER do this c4dpath = '{}\{}'.format(c4dfilesfolder, file), this is just bound to go wrong. Use os.path.join instead. You will have to debug your script yourself. Cheers, Ferdinand Result: Exported /Users/f_hoppe/Desktop/test/Untitled 2.fbx Exported /Users/f_hoppe/Desktop/test/Untitled 1.fbx Code (mostly AI generated): import c4d import os def SetFbxExportSettings() -> None: """Set the FBX export settings. """ plugin: c4d.plugins.BasePlugin = c4d.plugins.FindPlugin(c4d.FORMAT_FBX_EXPORT, c4d.PLUGINTYPE_SCENESAVER) data: dict = {} plugin.Message(c4d.MSG_RETRIEVEPRIVATEDATA, data) settings = data.get("imexporter", None) if settings is None: raise ValueError("Could not retrieve the FBX export settings.") settings[c4d.FBXEXPORT_FBX_VERSION] = False settings[c4d.FBXEXPORT_ASCII] = False settings[c4d.FBXEXPORT_CAMERAS] = False settings[c4d.FBXEXPORT_LIGHTS] = False settings[c4d.FBXEXPORT_SPLINES] = False settings[c4d.FBXEXPORT_INSTANCES] = False settings[c4d.FBXEXPORT_SELECTION_ONLY] = True settings[c4d.FBXEXPORT_GLOBAL_MATRIX] = False settings[c4d.FBXEXPORT_SDS] = c4d.FBXEXPORT_SDS_GENERATOR settings[c4d.FBXEXPORT_TRIANGULATE] = False settings[c4d.FBXEXPORT_SAVE_NORMALS] = True settings[c4d.FBXEXPORT_SAVE_VERTEX_COLORS] = False settings[c4d.FBXEXPORT_SAVE_VERTEX_MAPS_AS_COLORS] = False settings[c4d.FBXEXPORT_UP_AXIS] = c4d.FBXEXPORT_UP_AXIS_Y settings[c4d.FBXEXPORT_TRACKS] = True settings[c4d.FBXEXPORT_BAKE_ALL_FRAMES] = False settings[c4d.FBXEXPORT_PLA_TO_VERTEXCACHE] = False settings[c4d.FBXEXPORT_BOUND_JOINTS_ONLY] = False settings[c4d.FBXEXPORT_TAKE_MODE] = c4d.FBXEXPORT_TAKE_TAKES settings[c4d.FBXEXPORT_MATERIALS] = True settings[c4d.FBXEXPORT_EMBED_TEXTURES] = False settings[c4d.FBXEXPORT_SUBSTANCES] = True settings[c4d.FBXEXPORT_BAKE_MATERIALS] = True settings[c4d.FBXEXPORT_BAKEDTEXTURE_WIDTH] = 1024 settings[c4d.FBXEXPORT_BAKEDTEXTURE_HEIGHT] = 1024 def GetInputDocumentPaths() -> list[str]: """Opens a directory dialog to select a folder and returns a list of Cinema 4D documents that are in the selected folder or its subfolders. """ path: str = c4d.storage.LoadDialog( c4d.FILESELECTTYPE_ANYTHING, "Animations", c4d.FILESELECT_DIRECTORY) if not os.path.isdir(path): raise ValueError("The given path is not a directory.") files: list[str] = [] for root, _, filenames in os.walk(path): for filename in filenames: if filename.endswith('.c4d'): files.append(os.path.join(root, filename)) return files def main() -> None: """Main function. """ # Set the settings and get the inputs. SetFbxExportSettings() filePaths: list[str] = GetInputDocumentPaths() # Export the documents in the list to FBX. for path in filePaths: # Load the document. doc: c4d.documents.BaseDocument = c4d.documents.LoadDocument(path, c4d.SCENEFILTER_OBJECTS) if not doc: raise ValueError(f"Could not load the document at {path}.") # Get the first object in the document and set it as the selection so that it is exported. obj: c4d.BaseObject = doc.GetFirstObject() if not obj: raise ValueError(f"The document at {path} does not contain any objects.") doc.SetSelection(obj, c4d.SELECTION_NEW) # Export the document to FBX and close it. fbxPath: str = path.replace('.c4d', '.fbx') c4d.documents.SaveDocument(doc, fbxPath, c4d.SAVEDOCUMENTFLAGS_DONTADDTORECENTLIST, c4d.FORMAT_FBX_EXPORT) c4d.documents.KillDocument(doc) print(f"Exported {fbxPath}") if __name__ == '__main__': main()
  • Nothing happen when runing generate_solution_win.bat

    windows c++ 2024
    9
    0 Votes
    9 Posts
    1k Views
    gheyretG
    Yeah, it's a little bit anoying, but the problem's solve! Ready for rocking with C++! wohoo~