• Reading console output - possible?

    Cinema 4D SDK r20 c++ python
    11
    0 Votes
    11 Posts
    3k Views
    P
    I already guessed so. Thanks, I think we can close this post. -Pim
  • Viseme RIG test

    General Talk python
    6
    0 Votes
    6 Posts
    3k Views
    Leo_SaramagoL
    Hi! You could go for CTracks via Python. You'd have to get the track for a position parameter, for example, or create one, then get curve, then add keys. Later, you could simply range map it back to your Xpresso rig. it It's definitely doable!
  • R20 Script State Function

    Moved Cinema 4D SDK python r20
    7
    0 Votes
    7 Posts
    2k Views
    M
    Thanks a_block, Sadly I had to disable the state() function because it breaks (delays forever) Material Preview/Shader rendering. This State() function should somehow be isolated if possible ... but i guess this is the limitation of "checking the gui state". kind regards mogh
  • Add functions to python via C++ SDK [R20]

    Cinema 4D SDK c++ python
    4
    0 Votes
    4 Posts
    2k Views
    Y
    Hi Víctor, To retrieve parameters a function must be initialized with PYFN_FLAGS::KEYWORDS. Then use pylib.ParseTupleAndKeywords() to get the value for each parameter. The following code shows the implementation of a function which expects a string, an integer and a float: static _PyObject *extendpyapi_PassParameters(_PyObject *self, _PyObject *args, _PyObject *keywords) { PythonLibrary pylib; String str; Int32 integer = 0; Float real = 0.0f; const Char *kwlist[] = {"str", "integer", "real", nullptr}; if (!pylib.ParseTupleAndKeywords(args, keywords, "$if", kwlist, &str, &integer, &real)) return nullptr; if (str.Content()) GePrint("Parameter str: " + str); GePrint("Parameter integer: " + String::IntToString(integer)); GePrint("Parameter real: " + String::FloatToString(real)); return pylib.ReturnPyNone(); } ... moduleFunctions[1].Init("PassParameters", (PyFn)extendpyapi_PassParameters, PYFN_FLAGS::KEYWORDS, "PassParameters() - Extend Python API");
  • 0 Votes
    3 Posts
    2k Views
    Caleidos4DC
    Now Work Thanks Andreas
  • 2 Votes
    7 Posts
    5k Views
    a_blockA
    There is no way to get a filtered list of objects visible in the timeline. Sorry.
  • Removing color picker from ColorField

    Cinema 4D SDK python r20
    9
    1 Votes
    9 Posts
    2k Views
    M
    And sorry @kbar, @C4DS, @aturtur I should have found it earlier, but after looking at how to implement it, I figured out it's already possible since R21 with the flag DR_COLORFIELD_NO_SCREENPICKER import c4d class MyDialog (c4d.gui.GeDialog): def CreateLayout(self): self.AddColorField(1000, c4d.BFH_LEFT | c4d.BFV_TOP, colorflags=c4d.DR_COLORFIELD_NO_SCREENPICKER) return True if __name__=='__main__': global dialog dialog = MyDialog() dialog.Open(c4d.DLG_TYPE_ASYNC, xpos=-2, ypos=-2) Cheers, Maxime.
  • RemoveUserData does not fully remove User Data

    Cinema 4D SDK python
    4
    0 Votes
    4 Posts
    2k Views
    D
    This worked. Thank you.
  • Render to texture for Cinema 4D

    General Talk
    2
    0 Votes
    2 Posts
    2k Views
    a_blockA
    Hi, congratulation to your first plugin. Looks nice! Cheers, Andreas
  • LayerShader add Layers still not possible?

    Cinema 4D SDK python
    3
    0 Votes
    3 Posts
    1k Views
    indexofrefractionI
    thats a pity... i can convert c4d layer shaders to vray layer shaders but cant do it in the other direction, because i cant create layer shaders ... sigh
  • submenu for python plugin

    Cinema 4D SDK python
    7
    0 Votes
    7 Posts
    2k Views
    indexofrefractionI
    yup.. well.. i dont expect that to change very soon... so i guess we have to live with it still thanks for your patient support
  • Importing Modules (again)

    Cinema 4D SDK
    3
    0 Votes
    3 Posts
    2k Views
    A
    damn. totally didn't look there. sorry. Alfie
  • 0 Votes
    6 Posts
    3k Views
    J
    Hi, thanks but i managed to fix it. It wasnt a Cinema4d related error. Apparently a bad argument to one of python methods was causing it to return the filepath of the script instead.
  • Priority confusion

    Moved Cinema 4D SDK python r19
    8
    0 Votes
    8 Posts
    3k Views
    chuanzhenC
    For viewport delay: i rewrote Skin Deformer ,Add a Aim Object to Check DeformCacheDirty To achieve my purpose(keep viweport realtime Refresh),yes ,it work. I have been updating the post, hoping that I can understand what the problem is on the right path, instead of exploring the working mechanism of Cinema 4D in other ways. Although I don't get the official answer, this will not dispel my enthusiasm for exploration the answer. (English is not very good, I hope to understand what I express)
  • Issue Changing Modeling Axis

    Cinema 4D SDK python r20
    3
    0 Votes
    3 Posts
    2k Views
    D
    Thanks for the solution and explanation Yannick. It's working perfectly now and I can finish converting my scripts.
  • Python Effectors

    Moved Cinema 4D SDK python
    5
    0 Votes
    5 Posts
    2k Views
    B
    Thanks dskeith, that code worked perfectly. Thanks for that!
  • Set Asset Paths in python

    Cinema 4D SDK python r20
    5
    0 Votes
    5 Posts
    2k Views
    B
    Cool. Will do.
  • How to use c4dpy for Cinema4D R20 SP1

    Cinema 4D SDK
    18
    1 Votes
    18 Posts
    11k Views
    a_blockA
    @mikeudin Thanks for making us aware. We'll change the link with the next docs update.