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

    No refresh for deformer.

    Scheduled Pinned Locked Moved SDK Help
    9 Posts 0 Posters 672 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 03/12/2004 at 11:53, xxxxxxxx wrote:

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

      ---------
      Hi list 🙂

      I have a problem with a plug that get like a argument a external spline.
      The plugin is a standard deformer that use the spline as link to deform object.
      When i modify spline points or global matrix , the plugin don't refresh.

      Any help?

      Thanks
      Renato T.

      ps. sorry for english, i hope that someone understand what i mean.

      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 05/12/2004 at 03:54, xxxxxxxx wrote:

        you have to overload the CheckDirty function. More info in the SDK docs.

        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 05/12/2004 at 04:00, xxxxxxxx wrote:

          Katachi,

          in SDK i see:
          You can overload this function to check for a change in a deformer object manually. This example will make your deformer update every frame.

          Can i overload this function to see if a spline is change?

          Thanks 🙂
          Renato T

          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 05/12/2004 at 04:09, xxxxxxxx wrote:

            yes, you could use GetDirty() to check if the checksum changed.

            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 05/12/2004 at 04:35, xxxxxxxx wrote:

              THANSK! IT WORK!

              Cheers
              Renato T.

              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 05/12/2004 at 05:26, xxxxxxxx wrote:

                🙂 good luck with your plugin.

                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 05/12/2004 at 05:40, xxxxxxxx wrote:

                  Thanks, but there are some little things that i must verify.
                  With old scene this seem not work, with a fresh scene it's working.

                  Maybe that i wrong.

                  void PathDeformer::CheckDirty(PluginObject* op, BaseDocument* doc)
                  {
                       BaseContainer *data = op->GetDataInstance();
                       BaseObject *spline=data->GetObjectLink(PATHDEFORMER_SPLINE,doc);
                       if (spline)
                       {
                            if (spline->IsDirty(DIRTY_DATA) )
                            {
                                 //GePrint("Points Changed");
                                 op->SetDirty(DIRTY_DATA);
                            }

                  if (spline->IsDirty(DIRTY_MATRIX))
                            {
                                 //GePrint("Matrix Changed");
                                 op->SetDirty(DIRTY_MATRIX);
                            }
                            else GePrint ("damn!");
                       }
                  }

                  what do you think?

                  thanks
                  Renato T.

                  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 05/12/2004 at 06:01, xxxxxxxx wrote:

                    I wouldn´t do it with isDirty but with GetDirty()!

                    Create a private member in your object class, sth like:

                    private:
                    ULONG s_dirty;

                    then use something like (pseudo-code) :

                    ULONG dirty_bit = spline->GetDirty(DIRTY_DATA|DIRTY_MATRIX);  
                    if(dirty_bit!=s_dirty)  
                    {  
                        s_dirty = dirty_bit;  
                        op->SetDirty(DIRTY_MATRIX);   
                        /*Or DIRTY_DATA depending on when your deformer updates*/  
                    }
                    

                    Katachi

                    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 05/12/2004 at 06:23, xxxxxxxx wrote:

                      Ok, now it work... it will work, must test 🙂

                      Thanks
                      Renato T.

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