Author Topic: reorder cameras  (Read 710 times)

0 Members and 1 Guest are viewing this topic.

Offline andy.engelkemier

  • Sr. Member
  • ****
  • Posts: 400
reorder cameras
« on: March 14, 2019, 03:39:49 pm »
please add the ability to reorder cameras, just like models in the scene.

Working off a list in order, then someone asks to see a variation of camera 2 when you're done with camera 15? Now you get
camera 14
camera 15
camera 2b
camera 16
camera 17

I'd really like 2b to be next to 2a.
You wouldn't think it, but it happens more often that you'd think.

Offline Will Gibbons

  • Hero Member
  • *****
  • Posts: 2849
  • willgibbons.com
    • My Website
Re: reorder cameras
« Reply #1 on: March 26, 2019, 03:19:29 pm »
I can agree that this would be nice!

Offline MWo

  • Hero Member
  • *****
  • Posts: 851
  • Senior Technical Consultant @ INNEO (Germany)
    • german KeyShot page from INNEO Solutions
Re: reorder cameras
« Reply #2 on: March 28, 2019, 12:25:08 pm »
It is a workaround, but studios with just activated camera enable this.
Haven’t tried it yet, but isn’t reorder of cameras available in the scene tree?

Offline mattjgerard

  • Hero Member
  • *****
  • Posts: 1490
Re: reorder cameras
« Reply #3 on: March 28, 2019, 02:01:43 pm »
It is a workaround, but studios with just activated camera enable this.
Haven’t tried it yet, but isn’t reorder of cameras available in the scene tree?

Hey Marco, I tried setting up a studio with a  couple cameras, activated one in the studio and I didn't notice any difference. Trying to click and drag a camera in the camera tab list doesn't' work, just toggles through the cameras as you drag over them. Can't reorder in the scene tree either. This has been an ongoing wish for me, so I'm glad other people are requesting it too.

Maybe I'm missing something that you are doing?

Offline MWo

  • Hero Member
  • *****
  • Posts: 851
  • Senior Technical Consultant @ INNEO (Germany)
    • german KeyShot page from INNEO Solutions
Re: reorder cameras
« Reply #4 on: March 29, 2019, 01:51:21 am »
Hey Matt.

For example:
- create studio 1 that has camera 1 applied and nothing else
- create studio 2 with camera 2

Now you can re-order the studios in the list. And activating the studio sets the applied camera active.

That's all

Cheers
Marco

Offline mattjgerard

  • Hero Member
  • *****
  • Posts: 1490
Re: reorder cameras
« Reply #5 on: March 29, 2019, 05:32:49 am »
I understand what you are talking about now. Might work in some cases, but still doesn't scratch my itch to have everything in order in the camera tab. Can reorder most everything else, so in my list of 20 cameras would be nice to be able to get them in order so they appear in the right order in the studio selection drop down. I am starting to use studios more and more for organizing stuff, but I still am picky about wanting to be able to shuffle cameras in the list as well.

Good option, though.

Offline andy.engelkemier

  • Sr. Member
  • ****
  • Posts: 400
Re: reorder cameras
« Reply #6 on: March 29, 2019, 05:39:38 am »
There actually IS a solution...but you won't like it.

Go to camera 1, duplicate it
go to camera 2, duplicate it
you see where I'm going. Duplicate them all, in order

Now delete the originals

But is that Really something you want to spend 10 minutes doing?

Offline jbeau

  • Full Member
  • ***
  • Posts: 148
    • RPA
Re: reorder cameras
« Reply #7 on: July 27, 2019, 01:49:03 pm »
Here's a script that does this but makes every camera, "Perspective".
Capitalization is first then alpha, followed by numeric.
IE: View, cam, shot, shot1

I don't think there is a function to getCameraLens, such as ortho and pano.

Use at your own risk, save file prior to running:)
Code: [Select]
# AUTHOR jbeau3d
# VERSION 0.0.1
#sort camera alphabetically by name

cameras = lux.getCameras()
cameras.sort()

for cam in cameras:
    #get camera data
    lux.setCamera(cam)
    camData = lux.getSphericalCamera(cam)
    camDis = lux.getCameraDistance(cam)
   
    print(cam, "is now active")
    print(cam, camData, camDis)

    #assign camera attributes
    az=camData[0]
    inc=camData[1]
    tw=camData[2]
    print(cam,"azimuth:", az)
    print(cam,"inclination:", inc)
    print(cam,"twist:", tw)

    #rebuild camera
    lux.removeCamera(cam)
    lux.newCamera(cam)
    lux.setCamera(cam)
    print(cam, "is now being set")
   
    #set camera attributes
    lux.setSphericalCamera(azimuth=az, incl=inc, twist= tw)
    lux.setCameraDistance(dist =camDis)
    lux.saveCamera(cam)
« Last Edit: July 27, 2019, 02:08:26 pm by jbeau »