Page 1 of 1

3D cube image with textures?

PostPosted: Fri Aug 10, 2012 08:21
by SegFault22
Hey all, I have seen some images here and there that look similar to the ones of the topic post for the MoreOres mod, like so:
Image
I would like to know if there is a way to make custom images like this outside of minetest, and if so, what would one do to go about generating these images (special trick with rotating images or something) or where would someone find a ''program'' that is capable of making images like this?

PostPosted: Fri Aug 10, 2012 08:27
by cornernote
I got them using some crude hacks in the C++ code. The code is in my GameWiki.

If you find a better way please let me know.

PostPosted: Fri Aug 10, 2012 08:53
by SegFault22
Ah, how can I get that code to make an image?

PostPosted: Fri Aug 10, 2012 09:40
by xyz
You may also use this .sh script
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
w1=$((`identify -ping -format %w "$1"`-1)).5
h1=$((`identify -ping -format %h "$1"`-1)).5
w2=$((`identify -ping -format %w "$2"`-1)).5
h2=$((`identify -ping -format %h "$2"`-1)).5
w3=$((`identify -ping -format %w "$3"`-1)).5
h3=$((`identify -ping -format %h "$3"`-1)).5

convert -matte \
     \( $1 -rotate 90 -brightness-contrast -13 -matte -virtual-pixel transparent \
        +distort Affine "0.5,$h1 0.5,0.5   0.5,0.5 -14.5,-8  $w1,$h1 14.5,-8" \) \
     \( $2  -matte -virtual-pixel transparent \
        +distort Affine "$w2,0.5 0.5,0.5   0.5,0.5 -14.5,-8  $w2,$h2 0.5,16.5" \) \
     \( $3 -brightness-contrast -25   -matte -virtual-pixel transparent \
        +distort Affine   "0.5,0.5 0.5,0.5   0.5,$h3 0.5,16.5  $w3,0.5 14.5,-8" \) \
     -background transparent -layers merge +repage \
     isometric_cube.png


Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
./cube.sh default_furnace_side.png default_furnace_front.png default_furnace_side.png

will produce this image Image

PostPosted: Fri Aug 10, 2012 09:48
by Calinou

PostPosted: Fri Aug 10, 2012 11:12
by cornernote
Xyz, I don't suppose you have an imagemagick script that supports node boxes?

PostPosted: Fri Aug 10, 2012 11:26
by xyz
cornernote wrote:Xyz, I don't suppose you have an imagemagick script that supports node boxes?

I think that's impossible with only imagemagick.

PostPosted: Sat Aug 11, 2012 19:06
by SegFault22
Thank you, I'll try the .sh script now...
er, how would one ''use'' it in windows? I can't seem to find how...