Daimonin
Members login
Sign Up!      problems?
N F
* Daimonin Forum
Home Help Search Calendar

Welcome Guest, you have to register to post here.
Search

News

Stats
74035 Posts in 6702 Topics by 8113 Members
Latest Member: honda
Daimonin Forum  |  Contributions  |  Graphics (Moderators: Sherock, subaru)  |  Topic: POV-ray configurations for creating arch images « previous next »
Pages: [1] 2 Go Down Print
Topic: POV-ray configurations for creating arch images  (Read 1609 times)
LordGrunt
Administrator
*
*


Karma: +7/-1
Posts: 289



View Profile
« on: April 16, 2008, 06:58:22 pm »

This set of configurations was developed for POVRay fo Windows, but scene code is platform independant. But files quickres.ini and povray.ini, i simply dont know if or how they are used on other OS's. Very likely that quickres.ini is used in this specific editor to display render modes in top-left corner (pull down list).

But before starting scripting, configure your output:
Find POVRAY.ini file, edit and append lines:
Code:
Output_File_Type=N 
Output_Alpha=on
that forces POVRay to generate PNG with alpha channel

For now, as a good beggining, basic setup for creating flat floor tiles.

EDIT: important update about camera angle and position, doesnt apply for floors, but for others, yes.

============== FLOORS ===============
Code:
#include "colors.inc"

global_settings {
  assumed_gamma 1.0
}

camera {   
  orthographic
  location  <30, 23.6, 30>
  look_at   <0.0, 0.0,  0.0>
  right     x*image_width/image_height
   angle 32.3
}

light_source { <40,40,40> White shadowless}
box {
  <-10, -.1, -10>  // one corner position <X1 Y1 Z1>    leave this as it is,
  < 10,  0,  10>  // other corner position <X2 Y2 Z2>   top face is our floor
  pigment {color Yellow}
  // texture
  // normal
  // finish
  }

^ thats actual scene content, to render this is needed:

edit quickres.ini:
Code:
[Floor tile-large preview (480x230, No AA)]
Width=480
Height=230
Antialias=Off

[Floor tile (48x23, No AA)]
Width=48
Height=23
Antialias=Off
============== /FLOORS ==============
thats all for now Smiley whenever i'll discover some more possibilities, i'll update this topic


EDIT:

created sample of config for tall objects. since image of floor is 48x23, i doubled the width to make 48x96. its quite good placeholder for street lamp for example. atm, objects wider than floor tile cant be used (but working on it Smiley )


============== OBJECTS 48x96 ==============
edit: update to camera position&angle:
Code:

camera {   
  orthographic
  location  <30, tan(ang/57.2957795)*sqrt(2)*30, 30>
  look_at   <0.0, 0.0,  0.0>
  right     x*image_width/image_height
   angle 32.1
}

box {
  <-10, -.1, -10>  // one corner position <X1 Y1 Z1>    leave this as it is,
  < 10,  0,  10>  // other corner position <X2 Y2 Z2>   top face is our floor
  pigment {color Yellow}
  // texture
  // normal
  // finish 
translate -24.8*y
  }


and corresponding quickres.ini entry:
Code:
[tall object ( 48x96, no AA)]
Width=48
Height=96
Antialias=Off         

[tall object-preview ( 240x480, no AA)]
Width=240
Height=480
Antialias=Off


============== /OBJECTS 48x96 =============

EDIT:

and next update, object 96x96 . i commented most important changes
last and most important configuraton i think, because it allows to create almost any kind of object.

============== OBJECTS 96x96 ==============
Code:
#include "colors.inc"

global_settings {
  assumed_gamma 1.0
}

//edit: following camera config needs update,
//hold with using until proper values are discovered
//or try find them yourself :)

camera {   
  orthographic
  location  <30, tan(ang/57.2957795)*sqrt(2)*30, 30>
  look_at   <0.0, 0.0,  0.0>
  right     x*image_width/image_height
   angle 60.16                                               // this angle needs update
}

light_source { <40,40,40> White shadowless}   

declare floor1 = box {
  <-10, -.1, -10>  // one corner position <X1 Y1 Z1>    leave this as it is,
  < 10,  0,  10>  // other corner position <X2 Y2 Z2>   top face is our floor
  pigment {color Yellow}
  // normal
  // finish 
  }
   
union {                                // this is put to group objects, so they all get translated properly
object {floor1}
translate -24.47*y              // <--needs update as well...
}


and corresponding quickres.ini entry:
Code:
[big object ( 96x96, no AA)]
Width=496
Height=96
Antialias=Off         

[big object-preview ( 480x480, no AA)]
Width=480
Height=480
Antialias=Off

============== /OBJECTS 96x96 =============

NEW:
============== OBJECTS 144x192 =============
Very usefull for bigger objects, it is able to hold up to 3x3 grid and a lot units in height, far more than game can display properly.
Code:
#declare Dai_Cam =
camera {   
  orthographic
  location  <30, tan(ang/57.2957795)*sqrt(2)*30, 30>
  look_at   <0.0, 0.0,  0.0>
  right     x*image_width/image_height
   angle 81.6
}
camera { Dai_Cam}

#declare Dai_Sun = light_source { <240,340,100> color rgb <1,1,1> }//shadowless   
light_source { Dai_Sun }

#declare floor1 = box {
  <-30, -.001, -30>  // one corner position <X1 Y1 Z1>    leave this as it is,
  < 30,  0,  30>  // other corner position <X2 Y2 Z2>   top face is our floor
  pigment {color Yellow}
}

union{
 object {floor1 pigment{ checker pigment{color Blue*0.3}, pigment{color Red*.4}  scale 20 translate <10,0,-10> }}
   //this checkered floor meets in size 3x3 game tiles of grid.
   // use with care as its quite big space
   //checkers define areas of single tiles
   //comment it out if not needed
translate <0,-tan(ang/57.2957795)*sqrt(2)*30*1.65-0.7,0> //dont ask me how i got it. i have no clue :)
}

============== /OBJECTS 144x192  ============

============== XYZ Axes Model  ============
this is definition of object that is supposed to help a bit in case you loose orientation where is what.
Code:
#declare axes = union {
 cylinder {0*x,10*x,.5 pigment{color rgb <1,0,0>}  }
text { ttf "crystal.ttf" "X",  .1,  0 pigment{color rgb <1,0,0>} rotate y*45 scale 5 translate x*10}
 cylinder {0*y,10*y,.5 pigment{color rgb <0,1,0>}  }
text { ttf "crystal.ttf" "Y",  .1,  0 pigment{color rgb <1,0,0>} rotate y*45 scale 5 translate y*10}
 cylinder {0*z,10*z,.5 pigment{color rgb <0,0,1>}  }
text { ttf "crystal.ttf" "Z",  .1,  0 pigment{color rgb <1,0,0>} rotate y*-135 scale 5 translate z*10}
}   
//NOTE: in case of problems with font name, replace with anything suitable. if other than ttf, change 'ttf' directive as well
============== /XYZ Axes Model   ============

the question is, do i correctly assume that on arches should be no shadows?
actually, using shadowless camera is sometimes needed, sometimes its not the best choice.
best bet in case of notorious shadow problems with specific object is to put 'no_shadow' directive at the end of object definition.
« Last Edit: May 02, 2008, 04:27:10 pm by LordGrunt » Logged

CadaverForSale.com

Gadu-Gadu: 8194627
smacky
Administrator
*
*
*
*
*


Karma: +114/-96
Posts: 5251



View Profile
« Reply #1 on: April 16, 2008, 07:45:31 pm »

For now, as a good beggining, basic setup for creating flat floor tiles.
Can you post sample images? I may be needlessly concerned but the idea of 1000s of generated floor tiles fills me with dread for a number of reasons.

Quote
-allow higher floor, like with bush scticking out above floor (if this is done, all other object will be possible)
MT/Gecko will need to fill in the details here, but there is some issue with floors with bits sticking up (I can't remember exactly, but you can see it by putting, eg, an earth floormask on a wooden bridge with railings floor IIRC).

But otherwise, sounds good. Smiley
Logged

LordGrunt
Administrator
*
*


Karma: +7/-1
Posts: 289



View Profile
« Reply #2 on: April 16, 2008, 08:23:24 pm »

i was thinking about farm floor tiles as an example, few have plants rising above floor itself. but what i mean "to allow higher floor" is to actually use pov to create objects, floor itself doesnt bug me that much Smiley though its possible to create some really nice animations of floors (if they can be animated) like river flowing.

Logged

CadaverForSale.com

Gadu-Gadu: 8194627
smacky
Administrator
*
*
*
*
*


Karma: +114/-96
Posts: 5251



View Profile
« Reply #3 on: April 16, 2008, 08:42:24 pm »

Yes I hadn't though of the farm floors. Hm, I wish I could remember what the problem was or even if it is fixable or not.

POV to create objects sounds good.

Floor animations were removed for B4 (water used to be animated) because it is a lot of work for the server (maps with water squares tend to have quite a lot of water squares) for little real benefit.

With the animation done client-side this will no longer be a problem (presumably people running Dai on pocket calculators can turn off floor anims).

I think floor anims would be a big improvement.
Logged

tehill
Lesser Moroch Avatar
*
*


Karma: +11/-2
Posts: 985



View Profile
« Reply #4 on: April 16, 2008, 09:34:18 pm »

Fringed floor tiles have been used in Daimonin for a long time. grass.101.png, don't think there is any problem if you stick to 48 width and just go up.

Nice, a script for povray renderer, haven't used povray in several years, may have to dust it off.

Logged
LordGrunt
Administrator
*
*


Karma: +7/-1
Posts: 289



View Profile
« Reply #5 on: April 16, 2008, 10:48:32 pm »

updated top msg with recently created image, something i long time ago wanted to make, to be lvl-up animation Smiley
Logged

CadaverForSale.com

Gadu-Gadu: 8194627
Torchwood
MapMaster
*
*
*


Karma: +34/-5
Posts: 948



View Profile
« Reply #6 on: April 17, 2008, 06:24:23 am »


ooooo!  aaaaah!

That's pretty!

I like that a lot (as an example of what can be done)!
Logged

Nobbit
Lesser Moroch Avatar


Karma: +25/-11
Posts: 779



View Profile WWW
« Reply #7 on: April 17, 2008, 06:49:21 am »

looks great, LG! could immagine it to be used for teleportation spell (if ever implemented Wink) - outgoing direction Cheesy
Logged

LordGrunt
Administrator
*
*


Karma: +7/-1
Posts: 289



View Profile
« Reply #8 on: April 17, 2008, 08:02:18 pm »

i hope the filename of anim above did not inspire you nobbit for teleport spell idea.

its just that i was planning to take a quick sit before POV and make new teleporter image, though that was where the stairs began Smiley
Logged

CadaverForSale.com

Gadu-Gadu: 8194627
Nobbit
Lesser Moroch Avatar


Karma: +25/-11
Posts: 779



View Profile WWW
« Reply #9 on: April 17, 2008, 10:53:10 pm »

lol, nope, if u search the forum, u'll find that i have detailed idea about teleportation spell ... the teleports are very nice, although i think the look very much like stargates Wink
Logged

LordGrunt
Administrator
*
*


Karma: +7/-1
Posts: 289



View Profile
« Reply #10 on: April 17, 2008, 11:11:20 pm »

i added few more versions of teleporter (since its just switching few variables) to mapwiz svn;

/media/mapwz/lordgrunt

they are in separate png images, now waiting for good soul to arch them Smiley
Logged

CadaverForSale.com

Gadu-Gadu: 8194627
ThePlaneskeeper
Administrator
*
*
*
*


Karma: +47/-23
Posts: 1228



View Profile WWW
« Reply #11 on: April 18, 2008, 04:54:08 am »

this is quite fantastic, i like these alot!
Logged

badmotorfinger
Small ant


Karma: +0/-0
Posts: 6



View Profile
« Reply #12 on: April 18, 2008, 10:02:07 am »

Handy, that.   Grin



(Edit: I rebuilt the image on the server, half the size of the previous.  24x48 for player or player-sized-mob images, yes?)
« Last Edit: April 19, 2008, 12:42:13 am by badmotorfinger » Logged
LordGrunt
Administrator
*
*


Karma: +7/-1
Posts: 289



View Profile
« Reply #13 on: April 18, 2008, 04:09:54 pm »

how did you model it? looks cool, but would fit as some sort of giant i think Smiley players are 1.5 times higher than floor tile width afaik.
Logged

CadaverForSale.com

Gadu-Gadu: 8194627
Torchwood
MapMaster
*
*
*


Karma: +34/-5
Posts: 948



View Profile
« Reply #14 on: April 18, 2008, 05:47:01 pm »


Looks good - what does he look like 1/2 size?
Logged

Pages: [1] 2 Go Up Print 
Daimonin Forum  |  Contributions  |  Graphics (Moderators: Sherock, subaru)  |  Topic: POV-ray configurations for creating arch images « previous next »
Jump to:  

Page created in 0.158 seconds with 23 queries.
Powered by SMF 1.1.4 | SMF © 2006-2007, Simple Machines LLC
Seo4Smf v0.2 © Webmaster's Talks
Copyright 2008 Daimonin MMORPG  •  Terms of Service  •  XHTML  •  Daimonin sourceforge open source project