Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush GoZ API
      • Code Examples on Github
    • Forum
    • Downloads
    • Support
      • Support Procedures
      • Registered Developer Program
      • Plugin IDs
      • Contact Us
    • Categories
      • Overview
      • News & Information
      • Cinema 4D SDK Support
      • Cineware SDK Support
      • ZBrush 4D SDK Support
      • Bugs
      • General Talk
    • Unread
    • Recent
    • Tags
    • Users
    • Login
    1. Maxon Developers Forum
    2. General Talk
    Log in to post
    Load new posts
    • Newest to Oldest
    • Oldest to Newest
    • Most Posts
    • Most Votes
    • Most Views
    • B

      How to Generate Dynamic Functions?

      r21 python • • bentraje
      3
      0
      Votes
      3
      Posts
      515
      Views

      B

      Gotcha. Thanks for the code and confirmation.
      For my code, it's not really a simple printing the ID. Each ID corresponds with a separate function/script.
      I guess I'll just store them in a separate list. Separate ID list and separate function script list. Then execute them by matching index.

    • mfersaouiM

      Formula to calculate cloner radius

      c++ sdk • • mfersaoui
      3
      0
      Votes
      3
      Posts
      651
      Views

      mfersaouiM

      @r_gigante

      Hi Riccardo, thank you for your detailed response. That allowed me to find the exact formula.

      l / (2 * tan((180 / n) * 3.14159 / 180))

      Regards, Mustapha

    • mfersaouiM

      Calculate the rounding radius max value of a n-Side object

      c++ sdk • • mfersaoui
      3
      0
      Votes
      3
      Posts
      526
      Views

      mfersaouiM

      @Cairyn
      Hi,
      Thank you.

      Solution:

      Float GeIncircle(Int32 n, Float r) { return r * cos(PI / n); } Float max_rrad = GeIncircle(n, r);
    • D

      Error reading resource for Cinema4D after installing redshift.

      r20 • • danicusmitus
      2
      0
      Votes
      2
      Posts
      940
      Views

      M

      https://developers.maxon.net/forum/topic/11570/plugin-affecting-c4d-modules-startup/9

    • W

      Ptex Shader Progress

      c++ windows r21 • • wuzelwazel
      8
      2
      Votes
      8
      Posts
      1.5k
      Views

      r_giganteR

      Hi @wuzelwazel, thanks a lot for sharing your progresses on the Ptex Shader and for sharing your code.

      I've moved the thread to the more appropriate "General Programming & Plugin Discussions" hoping other developers could contribute to the discussion.

      Cheers, Riccardo

    • G

      This topic is deleted!

      • • gsmetzer
      2
      0
      Votes
      2
      Posts
      5
      Views
    • R

      Determine if a polygon is facing the camera

      python r20 • • rui_mac
      5
      0
      Votes
      5
      Posts
      926
      Views

      R

      Once again, thank you, Manuel.
      I had to do a few changes and it is working now.
      I even made it select the faces that are within a certain angle from the camera.
      Here is my code:

      for i,poly in enumerate(faces): a,b,c,d = poly.a,poly.b,poly.c,poly.d pta = points[a]*mg ptb = points[b]*mg ptc = points[c]*mg ptd = points[d]*mg v1 = pta-ptb v2 = ptb-ptc normal = v1.Cross(v2) normal.Normalize() if c != d: center = c4d.Vector((pta.x+ptb.x+ptc.x+ptd.x)/4.0,(pta.y+ptb.y+ptc.y+ptd.y)/4.0,(pta.z+ptb.z+ptc.z+ptd.z)/4.0) else: center = c4d.Vector((pta.x+ptb.x+ptc.x)/3.0,(pta.y+ptb.y+ptc.y)/3.0,(pta.z+ptb.z+ptc.z)/3.0) direction = cam_off - center norm_dir = direction.GetNormalized() angle = NINETY - normal.Dot(norm_dir) if (angle > 0.0 and angle < max_ang): selection.Select(i)
    • A

      Looking for help!

      jobs • • alexhammond
      2
      0
      Votes
      2
      Posts
      487
      Views

      CairynC

      Hi;

      if you're looking for Python development - I'd have some time on my hands. Long-time C4D user and developer (currently creating a Python-for-C4D course actually). Not in the UK though (mainland Europe).

      If you want to talk about some details, drop me a mail under cairyn (at) tigress (dot) com.

    • D

      c4dpy + Atom

      python • • darkgl0be
      4
      0
      Votes
      4
      Posts
      722
      Views

      D

      OK, thanks a lot for the quick answer!

      Cheers

    • H

      Are PluginStart() and PluginEnd() only for C++ plugins?

      python r21 • • heilei
      4
      0
      Votes
      4
      Posts
      762
      Views

      H

      Ok, got it. Thank you for your reply and clear explanation, r_gigante, much appreciated!

    • H

      Error in strings file documentation?

      • • heilei
      4
      0
      Votes
      4
      Posts
      718
      Views

      r_giganteR

      Hi @heilei thanks again for the comment! We'll try, where meaningful, to improve the typography in future releases.

      Best, R

    • Passion3DP

      This topic is deleted!

      • • Passion3D
      1
      0
      Votes
      1
      Posts
      2
      Views

      No one has replied

    • A

      Vertex map python setup

      • • akkanein
      3
      0
      Votes
      3
      Posts
      666
      Views

      CairynC

      Just to point out, I already answered & posted a full sample scene in this thread:
      https://www.c4dcafe.com/ipb/forums/topic/109504-python-vertex-map/
      plus a detailed explanation on how vertex map calculation works in a free post on my Patreon:
      https://www.patreon.com/posts/script-club-1-07-34384586

      (Just so we don't get work duplicated.)

    • H

      C4D R21 does not run on macOS within deamon any more

      • • hSchoenberger
      7
      0
      Votes
      7
      Posts
      2.1k
      Views

      H

      Any update?

    • Danchyg1337D

      Modeling Kernel Error : Invalid Object

      • • Danchyg1337
      2
      0
      Votes
      2
      Posts
      452
      Views

      ManuelM

      Hello and welcome to the forum,

      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 marked this thread as a question so when you considered it as solved, please change the state 🙂

      In your code you Resize the object after initialized for the modeling command. That's why.

      but probably a simpler way to achieve what you want is to access the polygon's data. The PolygonObject is inherit from PointObject where you can retrieve the pointer of the points' vectors with GetPointW

      sometthing like so will work

      Vector* padr{ pol->GetPointW() }; if (padr == nullptr) return maxon::NullptrError(MAXON_SOURCE_LOCATION); padr[3] = Vector(-2, 0, 0);

      You can have a look at our "roundtube" example in the sdk.zip file that ship with every Cinema 4D version. This example will show you how to create a primitive from scratch.

      Cheers,
      Manuel.

    • chuanzhenC

      Discussions about spline ik

      • • chuanzhen
      10
      0
      Votes
      10
      Posts
      2.0k
      Views

      chuanzhenC

      @zipit Thanks,this paper Parallel Transport Approach to Curve Framing
      I will follow your suggestion to explore RMF. It may be that the language barrier prevents us from communicating well, but I still get a lot of help from your answer. I use Google translate😊

    • R

      Trouble With Expression Editor

      • • Rurymhn
      6
      0
      Votes
      6
      Posts
      817
      Views

      R

      Bringing the viewport into focus worked... wow, I had a feeling it was something simple like that!

    • G

      Beginner Programmer C++ Libraries Needed for starting first plugin?

      • • geese780
      7
      0
      Votes
      7
      Posts
      1.1k
      Views

      G

      Hey Richard!

      Thank you for the response, I have VS2017 version 15.9 all set up now, I think..... haha. I can see all the solutions in VS as well, but I ran the powersheel commands without having 2017 installed and I could see them in 2019, do I need to re-run the command or is it on the compile side that 2017 is the right version?

      I've been reading through all that documentation and I have seen the resources on Git as well so thanks for helping me understand I'm looking in the right spots haha! Thanks for the help so far, I'm sure I'll be back soon with more questions haha!

      Cheers!

      MattG

    • kosmos3dK

      VRayToC4D Material Converter

      • • kosmos3d
      2
      0
      Votes
      2
      Posts
      563
      Views

      r_giganteR

      Thanks @kosmos3d for the contribution and making the whole community aware of it.

      Best, R

    • Danchyg1337D

      Missing Library

      c++ r20 • • Danchyg1337
      3
      0
      Votes
      3
      Posts
      531
      Views

      Danchyg1337D

      Thank you!