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

    Animate Camera

    Scheduled Pinned Locked Moved SDK Help
    3 Posts 0 Posters 304 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 15/07/2008 at 06:59, xxxxxxxx wrote:

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

      ---------
      Hi,

      I am currently working on a command plugin and trying to create and animate a camera from there.

      I am guessing that I can simply add a CameraObject to the scene. What do I do though to

      - set the camera's Pan, Tilt, Roll and other parameters

      - set these for a specific frame to animate the camera?

      Many thanks

      Markus

      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 23/07/2008 at 02:54, xxxxxxxx wrote:

        You can set the orientation and position of any object in Cinema4D with SetPos() and SetRot(). Alternatively you can set the object's matrix with SetMg() or SetMl() (global or local matrix).

        To set object parameters you have to change the object's container. Get the container, the ID of the parameter and call the according Set function. Check the example below, it changes the projection mode of the camera.

        > \> BaseContainer \*data = cam->GetDataInstance(); \> data->SetLong(CAMERA_PROJECTION, Pparallel); \> \> cam->Message(MSG_UPDATE); \> \> EventAdd(); \>

        You have to create tracks to animate objects. Check the CTrack/CCurve/CKey classes. CTrack::Alloc creates new tracks. Check the SDK docu and the Morphmixer SDK exmple for creating tracks and keys.

        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 13/08/2008 at 02:01, xxxxxxxx wrote:

          Many thanks Matthias,

          I found the CTrack/CCurve/CKey mechanism in the SDK and it works like a charm.

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