Announcement

Collapse
No announcement yet.

Hotkey for "Select Vray camera" possible?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Hotkey for "Select Vray camera" possible?

    Hello,

    I am desperately missing a hotkey to select the active vray camera.
    Is that possible? Or maybe with a scripted?

    Thanks

  • #2
    Here you go.

    You will notice i left you a second version of the macroscript commented out.
    Copy the contents in another script, and run it, to have a second command available which will select the active camera regardless of its class.

    EDIT: Latest version is v 0.02. It's been strengthened for when the current viewport is not a camera one.
    It will proceed looking for other views which are a camera, and select the first one it finds.
    If it finds none, it will select the first camera it finds (i.e. it's been created first. I think.) in the scene, even if they aren't set to a viewport.
    If it finds none, it will pop a message box, and warn the user.

    Keep reporting issues, thanks!
    Attached Files
    Last edited by ^Lele^; 18-08-2020, 09:17 AM.
    Lele
    Trouble Stirrer in RnD @ Chaos
    ----------------------
    emanuele.lecchi@chaos.com

    Disclaimer:
    The views and opinions expressed here are my own and do not represent those of Chaos Group, unless otherwise stated.

    Comment


    • #3
      many thanks! I will check it out tomorrow

      Comment


      • #4
        Just to add to Lele comment , I suggest adding Try() Catch() to the script like this
        Code:
        try(select (getActiveCamera())) catch()
        to avoid an error if you are currently not looking through a camera.

        Personally, I use the following script all the time :
        http://www.scriptspot.com/3ds-max/sc...-active-camera
        Last edited by M.Max; 18-08-2020, 08:47 AM.
        -------------------------------------------------------------
        Simply, I love to put pixels together! Sounds easy right : ))
        Sketchbook-1 /Sketchbook-2 / Behance / Facebook

        Comment


        • #5
          bah me. i thought it'd work with an undefined selection.
          Let me fix this, and also try and figure out what happens with multiple cameras.
          Lele
          Trouble Stirrer in RnD @ Chaos
          ----------------------
          emanuele.lecchi@chaos.com

          Disclaimer:
          The views and opinions expressed here are my own and do not represent those of Chaos Group, unless otherwise stated.

          Comment


          • #6
            Note you can also select the camera you are currently looking through from the dropdown menu in the view.

            Comment


            • #7
              Many thanks!
              I just tested it now and it works great. Even with several cameras and with or without the additonal "catch"-line. (3dsMax2021)

              I did not check out the script from scriptspot, but thanks also for that.

              Comment


              • #8
                Originally posted by BeneZ View Post
                Many thanks!
                I just tested it now and it works great. Even with several cameras and with or without the additonal "catch"-line. (3dsMax2021)

                I did not check out the script from scriptspot, but thanks also for that.
                V002 should work fine, yes, no need to edit it.
                Lele
                Trouble Stirrer in RnD @ Chaos
                ----------------------
                emanuele.lecchi@chaos.com

                Disclaimer:
                The views and opinions expressed here are my own and do not represent those of Chaos Group, unless otherwise stated.

                Comment

                Working...
                X