Renderer Switch - How to check for current Renderer?
I'm stuck again on a very simple script. I just want to code a macro that looks if scanline or mental ray is the current production renderer and then switches to the other one. But I just don't get it how to check for this. I've found a very similar topic in this forum, someone with the same problem, but he did not get any answers.
I tried "if (renderers.production == default_scanline_renderer)..." and "if (renderers.production == defaultScanlineRenderer)..." and so on but it won't work. I also tried to check for mental-ray-only attributes like "if (renderers.production.FinalGatherEnable2 == true)..." ,but when scanline is active it crashes my script.
I just don't know what to check for....
The little script so far:
macroscript renderSwitch category:"Custom" ( case of ( (renderers.production == default_scanline_renderer): renderers.production = mental_ray_renderer()--case 1 (renderers.production == mental_ray_renderer): renderers.production = default_scanline_renderer()--case 2 default: renderers.production = mental_ray_renderer()--default case )--end case of )--end macroscript
Hope you can help ;) And I'm a beginner, please keep that in mind :> Thanks!