• Load file from plugin directory

    Moved Cinema 4D SDK python sdk
    4
    0 Votes
    4 Posts
    825 Views
    ManuelM
    hello, @zipit thanks for your answer. for your next threads, please help us keeping things organised and clean. I know it's not your priority but it really simplify our work here. Q&A New Functionality. How to Post Questions especially the tagging part. I've added the tags and marked this thread as a question so when you considered it as solved, please change the state In the python help, you have a link to github where you can find examples. https://github.com/PluginCafe/cinema4d_py_sdk you will see sometimes in those example this code : path, fn = os.path.split(__file__) bmp = bitmaps.BaseBitmap() bmp.InitWith(os.path.join(path, "res", "gravitation.tif")) Just to add a few words about c4d.storage.GeGetC4DPath() That's the classic API. In c++ with the maxon API you have GetUrl In Python, in r20 symbol are not set and if you want to retrieve the resource directory it will return the Cinema4D's one and not your plugin's one. Cheers Manuel
  • 0 Votes
    3 Posts
    481 Views
    ferdinandF
    Hi, thank you for the clarification. Cheers zipit
  • Moving a group of spline points

    Cinema 4D SDK python sdk
    3
    1
    0 Votes
    3 Posts
    512 Views
    ManuelM
    hello, happy you found your solution, and thanks for the feedback Cheers Manuel
  • Default startup settings

    Cinema 4D SDK r20 maxon api sdk windows c++
    8
    0 Votes
    8 Posts
    2k Views
    O
    Thank you for the help @m_magalhaes
  • Browsing Plugin Paths

    Cinema 4D SDK c++ sdk r20
    4
    0 Votes
    4 Posts
    2k Views
    D
    Thank you both for the replies! Between both of them I have exactly what I need, thanks.
  • Set the "DrawCircle" orientation to face camera

    Cinema 4D SDK
    5
    0 Votes
    5 Posts
    631 Views
    mfersaouiM
    @m_magalhaes Thank you. I made some changes but its work! Cheers, Mustapha
  • 0 Votes
    5 Posts
    720 Views
    mfersaouiM
    @s_bach Thank you. Sorry for tags, I added tags in my topic but were not included. I don't know why.
  • 0 Votes
    5 Posts
    1k Views
    S
    Hello, I tested it with the Gradient Shader example from the cinema4dsdk and it works fine as far as I can tell. I just removed the check for ASSETDATA_FLAG::TEXTURESONLY: Bool SDKGradientClass::Message(GeListNode* node, Int32 type, void* data) { switch (type) { case MSG_GETALLASSETS: { AssetData* const assetData = static_cast<AssetData*>(data); // checks if only texture assets should be added if (assetData == nullptr) return true; BaseList2D* const baseList2D = static_cast<BaseList2D*>(node); if (baseList2D != nullptr) { // get the file name const Filename path = baseList2D->GetData().GetFilename(GRAD_FILE); // check if the file name is set if (path.IsPopulated()) { // add the file name assetData->Add(path, nullptr); } } break; } } return SUPER::Message(node, type, data); }; Regarding Shader hierarchies: I guess you can send the message to your child-shaders yourself, to make sure they receives the message. best wishes, Sebastian
  • Linearize an exponential function

    Cinema 4D SDK c++ sdk
    4
    0 Votes
    4 Posts
    585 Views
    mfersaouiM
    @r_gigante Finally I found the solution to linearize the subdivision expansion on Adaptive spline interpolation on the angle deviation. I just replaced the line : radVal = c4d.utils.DegToRad(90 * (1.0 - val) By : radVal = math.pow(val, -0.85) I changed also the slider user data unit to REAL if I want to keep it with a PERCENT unit I just multiply the value by 100 radVal = math.pow(val*100, -0.85) Here is demo: [image: 1565669857246-ezgif.com-optimize.gif]
  • [python] SetFont not working

    Cinema 4D SDK r20 sdk python
    6
    0 Votes
    6 Posts
    2k Views
    I
    @m_adam said in [python] SetFont not working: In which version are you? The code I posted is working nicely in R20.059. 20.059. Before i tried any methods, that's my fail. Not work for me. From new start of c4d. - it works
  • controlled rendering programmatically

    Cinema 4D SDK sdk python
    3
    0 Votes
    3 Posts
    543 Views
    ManuelM
    hi, without any further feedback, this thread will be considered as solve tomorrow. Cheers Manuel
  • Sperical floor issue

    Cinema 4D SDK sdk c++ python
    3
    0 Votes
    3 Posts
    584 Views
    ManuelM
    hi, without any further feedback, this thread will be considered as solve tomorrow. Cheers Manuel
  • DESC_PARENT_COLLAPSE Twirl Down

    Cinema 4D SDK r20 sdk c++
    5
    0 Votes
    5 Posts
    662 Views
    ManuelM
    hello, this thread will be considered as Solved tomorrow is you have nothing to add. Cheers Manuel
  • MoGraph Form Control

    Cinema 4D SDK c++ r20 sdk
    3
    0 Votes
    3 Posts
    697 Views
    ManuelM
    hello, if you have nothing to add, this thread will be considered as 'solved' and will be closed tomorrow Cheers Manuel
  • Retrieving Deformed Splines

    Cinema 4D SDK c++ r20 sdk
    3
    0 Votes
    3 Posts
    655 Views
    J
    Thanks for the reply, it really helped me out. John
  • Disable SimpleListView Item

    Cinema 4D SDK c++ r20 sdk
    2
    0 Votes
    2 Posts
    474 Views
    r_giganteR
    Hi Ogers thanks for reaching out us. With regard to your request, I confirm that to deliver the desired functionality you've to stick to TreeView since it's not possible to disable items belonging to a SimpleListView. Cheers, Riccardo
  • Large Delay with Python Interpreter in PyCharm

    Cinema 4D SDK r20 python sdk
    3
    0 Votes
    3 Posts
    667 Views
    M
    Hi @blastframe, I can only confirm what's @mp5gosu said, and confirm that c4dpy is a complete Cinema 4D executable, just opened as a python interpreter mode. So nothing to do here, unfortunately. Cheers, Maxime.
  • Pycharm - Invalid Python SDK

    Cinema 4D SDK r20 python sdk
    3
    1
    0 Votes
    3 Posts
    11k Views
    ?
    @m_adam said in Pycharm - Invalid Python SDK: Hi, @blastframe thanks for contact us. So far we never encounter this issue and we are not able to reproduce it so few ideas to try: Make sure you have permission to write in the Cinema 4D folder and subfolder. Flush the cache, https://stackoverflow.com/a/45099651. Send us your PyCharm log, see https://intellij-support.jetbrains.com/hc/en-us/articles/207241085-Locating-IDE-log-files Cheers, Maxime. Hi @m_adam, Thank you for the reply. I ran PyCharm as an Administrator and flushed the cache. I still received the same error. When I looked at the log, I found a lot of missing file errors, which made me think I had the python.exe (c4dpy.exe) file in the wrong location. When I moved the file to the same folder as the R20 .exe, PyCharm started working. I was confused about the file location because, while in the Install instructions from the C4D Python SDK Documentation has the c4dpy in the C4D folder, this image made it seem like it could exist in a separate folder: [image: 1558553507512-c4dpy_pycharm_win2.png] I would have expected a file location similar to the default Windows location: C:\Program Files\MAXON\Cinema 4D R20\python.exe Thank you again. I have one follow-up question that I'll ask as a new topic.
  • Customizing the Layout and Palettes

    Cinema 4D SDK r20 windows sdk
    3
    1
    0 Votes
    3 Posts
    923 Views
    O
    Hello @m_adam I see, I will have to use one of the other alternatives then. Thank you.
  • 0 Votes
    7 Posts
    1k Views
    fwilleke80F
    Thank YOU