How to draw a Spline with BaseDraw?



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

    On 10/08/2008 at 14:47, xxxxxxxx wrote:

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

    ---------
    Hi,

    I try to visualize a spline in the Draw() method of my Generator Object.

    The spline only exists in a SplineObject in my code, it's not existing in the ObjectManager or any virtual hierarchy. Is there any way to draw it in the editor?

    Using Line3D(const Vector & p1, const Vector& p2) to draw from one spline point to the next will not be very efficient, I suppose.

    Thanks for any tips!

    Greetings,
    Jack



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

    On 10/08/2008 at 15:12, xxxxxxxx wrote:

    Hi Jack :)

    Try: Bool DrawObject(BaseDrawHelp* bh, BaseObject* op, LONG drawpass)
    That helps you, to put in a BaseObject.

    bye



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

    On 10/08/2008 at 15:12, xxxxxxxx wrote:

    Hi Jack :)

    Try: Bool DrawObject(BaseDrawHelp* bh, BaseObject* op, LONG drawpass)
    That should help you.

    bye



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

    On 10/08/2008 at 15:53, xxxxxxxx wrote:

    Yeah, thanks :)
    I am sure that will help.

    But one more question:
    What if I have that SplineObject in a separate function?
    Should I store declare it as private in the class header to make it available in the Draw() method?

    Cheers,
    Jack



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

    On 11/08/2008 at 07:54, xxxxxxxx wrote:

    Hi Jack,

    Yes, make a copy of your spline and put it in a private member. But be careful. You have to dealloc the obejct after deleting the object (in deconstructor).


Log in to reply