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
    • Unread
    • Recent
    • Tags
    • Users
    • Login

    User Data keyframes not rendering with animation

    Scheduled Pinned Locked Moved PYTHON Development
    3 Posts 0 Posters 1.0k 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

      On 06/07/2018 at 01:41, xxxxxxxx wrote:

      Hi guys,

      Apologies for the vague title! I'm having an issue that may be more of a C4D thing than Python but either way here goes...

      Essentially, i've created a plugin that swaps (Octane) image textures using user data. I can keyframe the user data and the textures all swap accordingly - this works fine in the viewport and also when rendering a single frame.

      The issue i'm having is if I render out as an animation the keyframes on the user data aren't recognised, and it only renders out whatever the user data is set to on the current frame.

      I'm wondering if this is some sort of priority thing and maybe I can fix this by adding something to my code?

      I have workaround in which I can write a script that will create a take for each frame of the animation, but I would much prefer (and our animator will be less likely to strangle me) if we could render the animation directly.

      Any thoughts on this would be great.

      Thanks,

      Colin

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

        On 06/07/2018 at 02:08, xxxxxxxx wrote:

        Hello,

        what kind of plugin did you write? How exactly does it work?

        Just from the "symptoms" you describe: when something works in the viewport but not in animation rendering this is often caused by using GetActiveDocument() in a NodeData based plugin e.g. to resolve a link. That of course won't work since the "active" document is the document in the viewport, not necessary the documented rendered.

        Could that be an issue?

        best wishes,
        Sebastian

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

          On 10/07/2018 at 23:56, xxxxxxxx wrote:

          Hi Sebastian,

          Just want to say thanks for your help with this and it turns out your answer was exactly right.

          Managed to correct it by using node.GetDocument() instead of GetActiveDocument().

          Many thanks!

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