ScriptSpot

Forum topic · General Scripting

HIDE OBJS WITH CAMERAS

By alexnguyen · 2016-07-20

Description

hello , i am newbie in maxscript , I want to crreate a simple script , i have many cameras in scenes , for each camera i want hide some objs , how can i code it ? thank you for your help , sorry my bad english

Comments (2)

thank you for your help

alexnguyen · 2016-08-01

:D

`

pixamoon · 2016-07-28

Hi,

Did you try to use existing scripts:
Batch Camera Render
http://www.scriptspot.com/3ds-max/scripts/batch-camera-render
Prism
http://www.scriptspot.com/3ds-max/scripts/prism
LPM
http://www.scriptspot.com/3ds-max/scripts/l-pass-manager

but if you want to do new simple script - do u want to hide/unhide objects with changing cameras or only during render time ?

if during render time only:
I would start with adding custom attribute to camera with list of nodes to hide
Thank use callbacks or prerender/postrender scripts to hide/unhide those objects

Hide/unhide when changing camera is more tricky, but yuo can try with callbacks too (Viewport Redraw Callback + check if active camera - getActiveCamera())or just create rollout to switch cameras together with hiding/unhiding objects

Let me know which direction u want to go. Than I can help you with more details.

Cheers,
Pixamoon