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

    GVO, playback and rendering

    SDK Help
    0
    6
    460
    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
      Helper
      last edited by

      On 25/02/2016 at 05:02, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   R14 
      Platform:   Windows  ;   
      Language(s) :     C++  ;

      ---------
      Hi Folks!

      Is there an alternative to CheckIsRunning() that I can use inside of my object's GVO function? I can't use CheckIsRunning() because that seems to be global, and it causes my "if" statements to trip up when I'm rendering other documents. Is there another way here?

      Similarly, is there something for viewport playback as well? I may be needing to get info out of my object from documents in memory, and don't want another documents playback tripping up my object GVO satements/flags.

      Cheers,

      WP.

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

        On 26/02/2016 at 03:41, xxxxxxxx wrote:

        You can check the BUILDFLAGS for external rendering.

        https://developers.maxon.net/docs/cpp/2023_2/class_hierarchy_help.html#a6465804b4a9a847443626e21d3380fa4

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

          On 26/02/2016 at 04:04, xxxxxxxx wrote:

          Hi,

          I'm not completely convinced that it is a good idea to use CheckIsRunning() in GVO.
          Can you provide us with some more detail, what you are trying to achieve and what you are checking for in GVO?
          In the end GVO is called in all kinds of different contexts and I'm not sure it's a good idea to have different outcome, just because another task is running in parallel or not. Not even talking about waiting in GVO (an absolute NoNo!).

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

            On 27/02/2016 at 23:00, xxxxxxxx wrote:

            Hi Niklas - the external render build flag seems to have sorted out the first part, thanks!

            Hi Andreas - re CheckIsRunning() - that's why I was looking for another way 😉

            In my plugin, I'd like to switch to a lower polygon object during playback. Dealing with the low poly object isn't a problem. But I can't seem to find anything that'll let me test for timeline playback other than the global CheckIsRunning(). Is there anything else that can do this that's local to my object/scene?

            WP.

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

              On 29/02/2016 at 07:47, xxxxxxxx wrote:

              Hi,

              actually C4D automatically switches to displaying isoparms only, if scene update gets too slow. So if you provide a correct isoparm representation (BUILDFLAGS_ISOPARM), this could already help.
              Then it's probably a good idea to do a (or multiple) TestBreak() in your GVO, so C4D has a chance to interrupt GVO.
              Maybe then you could use the result from TestBreak() to switch to a lower res version in the next run (if still needed). Or what I did quite some time ago, when I detected an interruption, I) kept my progress, so I could continue at that very point on the next GVO (your dirty state evaluation needs to be rock solid then). Just ideas though.

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

                On 29/02/2016 at 16:34, xxxxxxxx wrote:

                Hi Andreas,

                Ideas are good! What I've done is made a statement that checks CheckIsRunning() for the animation flag, as well as checking the active document against the passed hh->GetDocument(). I think this is as close as I'll get. If I find any drawbacks with this, then I'll remove it. It's not a must-have as far as the plugin is concerned, just a handy thing for the user to have access to that's all.

                WP.

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