View Full Version : Something for you scripting gurus
02-27-2007, 04:11 PM
I've been wanting a script in Cinema 4D that would do the following for a while now:
1) Import an image.
2) Create a material with that image in the luminance and alpha channels.
3) Create a plane with -Z orientation and the same aspect ratio as the image.
4) Apply the new material to the plane.
I'm constantly repeating this task in projects and a script would save a ton of time. Since my scripting skills are non existent, I thought I'd see if anyone here would like to take a crack at it. Anyone?
02-27-2007, 07:46 PM
Is there any reason to not use the viewport backdrop for this? (besides the fact that it's also always the same res as your image rather than limited to the ogl bitmap resolutions).
02-27-2007, 08:13 PM
Thanks for the reply.
The type of project I'd be using this sort of thing for would be say, if I wanted to do a camera move through 15 logos, and I wanted bitmap images of each logo to be placed on transparent planes.
Basically, it would be a way to import 2d images into cinema's 3d space without manually going through all the steps necessary to create separate materials and correctly proportioned planes.
02-27-2007, 08:32 PM
not exactly what you want but certainly usefull for a part of the job : Adjust2bitmap from Majoul.
02-27-2007, 09:51 PM
OK, so I wrote a script that does the job - check the attached zip.
This was a quickie, so there's no error checking or anything. In other words, no warranty AS-IS stuff... but it seems to work just fine.
02-27-2007, 10:04 PM
Great job and thanks James, very handy!
02-28-2007, 06:25 AM
You're welcome :thumbsup:
Minor update, with proper undo support and basic sanity checks.
Download V0.3 here -> http://www.kaufeldt3d.com/plugs/imageplane_0.3.zip
02-28-2007, 06:25 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
vBulletin v3.0.5, Copyright ©2000-2013, Jelsoft Enterprises Ltd.