Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush Python 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
    • Recent
    • Tags
    • Users
    • Login

    Insert phong shading normals myself...

    Scheduled Pinned Locked Moved SDK Help
    3 Posts 0 Posters 371 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • H Offline
      Helper
      last edited by

      THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

      On 27/07/2009 at 03:49, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   R9.6 
      Platform:      Mac OSX  ; 
      Language(s) :     C++  ;

      ---------
      Hi there again!

      I'm using Cinema to calculate lightmaps by baking textures. NO , don't worry, this is not another question on how to bake textures! 😉

      No, this works fine so far. I'm doing this by picking every CPolygon from every PolygonObject in the polyginized Document, creating a new PolygonObject using the vertices stored in the CPolygon, adding the new object to the scene, assign a plain white material and do the bake.

      As said, this works well!

      But there's a small problem: I need to extract a new PolygonObject from the CPolygon because every polygon should have it's own lightmap when saving, to avoid variating quality (which would like odd at the end).

      But by doing so, the polygon looses its smooth vertex normals (phong normals, that's of course because the polygon doesn't have any neighbours anymore), so every polygon looks at the end like a plain plane. And this too looks quite... well... odd...

      Here's an example:
      This is how it should look like (Cinema) :

      And this is how it looks in my game:

      Now, is there any way to insert phong normals for the new created polygon myself? As it looks like, Cinema is doing it itself using the phong tag's parameters, so I fear the answer. But maybe there is some workaround?

      Thanks in advance,
      Mark

      1 Reply Last reply Reply Quote 0
      • H Offline
        Helper
        last edited by

        THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

        On 27/07/2009 at 05:00, xxxxxxxx wrote:

        This can be done using Normal tags. Check the SDK docu for Tnormal and VariableTag.

        cheers,
        Matthias

        1 Reply Last reply Reply Quote 0
        • H Offline
          Helper
          last edited by

          THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

          On 27/07/2009 at 05:30, xxxxxxxx wrote:

          Oops, looks like I did not check that as I should have done...

          ...sorry for posting obvius questions I could have answered myself by reading the SDK thoroughly.

          Thank you again!

          1 Reply Last reply Reply Quote 0
          • First post
            Last post