3DBOX Help + Ideas

A plethora of command-line scripts that perform geometric transforms, blurs, sharpens, edging, noise removal, and color manipulations.
Post Reply
corbanb
Posts: 17
Joined: 2013-09-29T19:29:36-07:00
Authentication code: 6789

3DBOX Help + Ideas

Post by corbanb »

Hi everyone,

I am working a project that will convert images using 3DBOX but not really sure how to go about this. Would love some ideas if possible. In this image (http://cl.ly/image/1U202s2Q0P2N) you can see I have 4 separate renderings of the same image in 3D. One thing to note is I don't need these combined into 1 image this is just an example of the angles I am looking to create. What I'd like to do is be able to build each one of these 1 at a time out of a single image using the 3DBOX script. Is this even possible? Would anyone have some ideas on what I could do to come up with a creative solution for this? Thanks so much!
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: 3DBOX Help + Ideas

Post by fmw42 »

It is possible. You would have to cut out a section for the top, buttom, left, right and center as single images from a normal face-on image (not at perspective). The center section could be put on the back or any blank image the same size. Note that when cutting out these sections, there will be left over corners that you will just throw away. After cutting out these sections, the top and bottom and left and right must have the same thickness so that all the sides are the same in depth. The top and bottom must be the same size. Similarly the left and right. Similarly the center front and center back. Then just order them consistently for the script.

However, if you are willing to have a bit less flexibility in orienting the result, you could use 3Dcover instead. It will cut the side automatically and piece them together for you. You don't have to have separate images for them.
corbanb
Posts: 17
Joined: 2013-09-29T19:29:36-07:00
Authentication code: 6789

Re: 3DBOX Help + Ideas

Post by corbanb »

That's very cool! Does this mean it will do the angles like I have show in this photo also? http://cl.ly/image/1U202s2Q0P2N Or just one side on the left as seen in the demo images?
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: 3DBOX Help + Ideas

Post by fmw42 »

3Dbox will do any angle. 3Dcover only rotates left or right.
corbanb
Posts: 17
Joined: 2013-09-29T19:29:36-07:00
Authentication code: 6789

Re: 3DBOX Help + Ideas

Post by corbanb »

Hi! So I started working on this script and have begun to get things working but am now running into an issue at the very end of the 3Dbox script that calls the '1tmp1.png' etc images starting at line 1082 of the script. I get the error it can't open that file. I am not sure what its looking for since those aren't in there anyplace. What is this used for and why does it error here?

Reference code:

Code: Select all

eval 'convert \
	\( '"$proc1"' -write 1tmp1.png \) \
	\( '"$proc2"' -write 1tmp2.png \) \
	\( '"$proc3"' -write 1tmp3.png \) \
	\( '"$proc4"' \) \
	\( '"$proc5"' \) \
	\( '"$proc6"' \) \
	$merge \
	$outfile'
Errors:

Code: Select all

convert: unable to open image `1tmp1.png': Permission denied @ error/blob.c/OpenBlob/2646.
convert: WriteBlob Failed `1tmp1.png' @ error/png.c/MagickPNGErrorHandler/1804.
convert: unable to open image `1tmp1.png': Permission denied @ error/blob.c/OpenBlob/2646.
convert: WriteBlob Failed `1tmp1.png' @ error/png.c/MagickPNGErrorHandler/1804.
convert: unable to open image `1tmp1.png': Permission denied @ error/blob.c/OpenBlob/2646.
convert: WriteBlob Failed `1tmp1.png' @ error/png.c/MagickPNGErrorHandler/1804.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: 3DBOX Help + Ideas

Post by fmw42 »

Those were temporarily added for debugging and should have been remove. I have uploaded a corrected version, so try that, but first repeat my example on my web site to be sure it works for you. It worked fine just now for me under IM 6.8.7.0 Q16 Mac OSX.

If you have trouble, first look on my home page at the Pointers to be sure you change the dir to /tmp and possibly set up the environment variables so that the script can locate IM. It looks like your current directory does not have write permission.

If still having trouble, post a link to your images or send them to me to fmw at alink dot net.

I have never tested the script with files that were not all the same square size.
corbanb
Posts: 17
Joined: 2013-09-29T19:29:36-07:00
Authentication code: 6789

Re: 3DBOX Help + Ideas

Post by corbanb »

Its been going pretty well. I removed those lines form my script and seem to be moving fairly well. I'll definitely let you know if anythings comes up! Thanks for your continued help.
Post Reply