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

    find all cameras C.O.F.F.E.E

    Scheduled Pinned Locked Moved SDK Help
    3 Posts 0 Posters 298 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 18/01/2009 at 10:14, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   9.1 
      Platform:      Mac OSX  ; 
      Language(s) :   C.O.F.F.E.E  ;

      ---------
      Hello!

      I need to find all cameras in a scene ? Include all parents list. how can I to do?

      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 18/01/2009 at 10:50, xxxxxxxx wrote:

        Here is an example that browses through the entire object hierachy. Basically you browse with GetDown(), GetUp()and GetNext(), GetPrev(). Check with GetType for the object's type.

        > \> Recursive(camera) \> { \>      while(camera) \>      { \>           if(camera->GetType() == Ocamera)     //check if it is a camera \>           { \>                //do something with camera \>                println(camera->GetName());     //prints the name of the camera \> \>                var parent = camera->GetUp(); \>                if(parent) \>                { \>                     //parent is the cameras parent \>                     //do something with parent \>                     println(parent->GetName());     //prints the name of the camera's parent \>                } \>           } \> \>           Recursive(camera->GetDown()); \> \>           camera = camera->GetNext(); \>      } \> } \> \> main(doc,op) \> { \>      Recursive(doc->GetFirstObject()); \> } \>

        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 18/01/2009 at 14:35, xxxxxxxx wrote:

          Thank you!!!

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