POV-Ray : Newsgroups : povray.binaries.images : Constant width grid Server Time
7 Aug 2024 05:21:09 EDT (-0400)
  Constant width grid (Message 11 to 17 of 17)  
<<< Previous 10 Messages Goto Initial 10 Messages
From: Mike Sobers
Subject: Re: Constant width grid
Date: 10 Jul 2006 13:05:00
Message: <web.44b28792e4538ab61009749b0@news.povray.org>
"Slime" <fak### [at] emailaddress> wrote:
> See "Re: TRON Game Grid..." in povray.newusers. The grid lines get bigger as
> they get farther away from the camera.
>
>  - Slime
>  [ http://www.slimeland.com/ ]

How's this look? All constant size, but using 3D "gridlines" seems to mimic
the effect better than any 2D pattern on the floor plane, since the pattern
becomes infinitely thin as it approaches the horizon.

-Mike

// ----------------------------------------

camera {
  location  <-15.0, 2, -15.0>
  direction 1.5*z
  right     x*image_width/image_height
  look_at   <-5.0, -4.0,  10.0>

// ----------------------------------------

#declare gridtex = texture {
 pigment { color White }
 finish { ambient 1 diffuse 0 }
}
#declare R = 0.025;
#declare i = 0;
#while (i<101)

        cylinder { <-50, 0, -50+i>, <50, 0, -50+i>, R texture {gridtex }
no_shadow}
        cylinder { <-50+i, 0, 50>, <-50+i, 0, -50>, R texture {gridtex }
no_shadow}

        #declare i = i+1;
#end

// ----------------------------------------


Post a reply to this message


Attachments:
Download 'gridtest.png' (40 KB)

Preview of image 'gridtest.png'
gridtest.png


 

From: Mike Sobers
Subject: Re: Constant width grid
Date: 10 Jul 2006 13:50:01
Message: <web.44b2925fe4538ab61009749b0@news.povray.org>
"Mike Sobers" <sob### [at] mindspringcom> wrote:

> How's this look? All constant size, but using 3D "gridlines" seems to mimic
> the effect better than any 2D pattern on the floor plane, since the pattern
> becomes infinitely thin as it approaches the horizon.
>
> -Mike
>

Of course, you'd need to add a } to the camera statement. There are some
limitations to this approach, as seen below.  Maybe the y-dimension
thickness of the cylinders could be scaled according to their distance from
the camera using a matrix transformation?  That would fix the fact that
objects look like they're sitting on top of the gridlines (which they are).
 You'd still have the problem of no shadows being cast on the gridlines.

It's sometimes hard to mimic 2D raster graphics with z-buffering using
"real" 3D objects.

Mike


Post a reply to this message


Attachments:
Download 'gridtest2.png' (53 KB)

Preview of image 'gridtest2.png'
gridtest2.png


 

From: Sebastian
Subject: Re: Constant width grid
Date: 10 Jul 2006 14:11:22
Message: <pan.2006.07.10.18.11.22.461604@gmx.de>
Am Mon, 10 Jul 2006 13:46:07 -0400 schrieb Mike Sobers:

> 
> Of course, you'd need to add a } to the camera statement. There are some
> limitations to this approach, as seen below.  Maybe the y-dimension
> thickness of the cylinders could be scaled according to their distance from
> the camera using a matrix transformation?  That would fix the fact that
> objects look like they're sitting on top of the gridlines (which they are).
>  You'd still have the problem of no shadows being cast on the gridlines.

Actually I was trying the same. At the moment I use a cone under the
camera as ground. Looks not too bad. I'll post some images later.

Sebastian


Post a reply to this message

From: Zeger Knaepen
Subject: Re: Constant width grid
Date: 10 Jul 2006 15:48:50
Message: <44b2af22$1@news.povray.org>
"Carl" <car### [at] semisouthcom> wrote in message 
news:web.44b263b7e4538ab670dc520d0@news.povray.org...
> "Zeger Knaepen" <zeg### [at] povplacecom> wrote:
>> I might be mistaken, but don't you loose the adaptive advantage of +am2
>> if you have +a0.0 ?
>
> Yes you do but if you have a very thin line going through a pixel it could
> easily be missed all together if its set to anything else.

oh, yes, ic, with +r4 or higher you do get an advantage by using +am2

... or am I totally misinterpreting the adaptive aa-method? :)

cu!
-- 
#macro G(b,e)b+(e-b)*C/50#end#macro _(b,e,k,l)#local C=0;#while(C<50)
sphere{G(b,e)+3*z.1pigment{rgb G(k,l)}finish{ambient 1}}#local C=C+1;
#end#end _(y-x,y,x,x+y)_(y,-x-y,x+y,y)_(-x-y,-y,y,y+z)_(-y,y,y+z,x+y)
_(0x+y.5+y/2x)_(0x-y.5+y/2x)            // ZK http://www.povplace.com


Post a reply to this message

From: Carl
Subject: Re: Constant width grid
Date: 10 Jul 2006 17:10:01
Message: <web.44b2c1a2e4538ab670dc520d0@news.povray.org>
I see everyone has been busy and things are looking better.  Now to try and
digest all this info.

Carl


Post a reply to this message

From: Tim Attwood
Subject: Re: Constant width grid
Date: 12 Jul 2006 06:21:26
Message: <44b4cd26@news.povray.org>
I seem to remember that TRON used vector graphics.
Instead of sweeping the electron beams to paint the
whole screen only the object outlines get painted.
Any background bluring might have been intentionally
added when they merged the layered images together.


Post a reply to this message

From: Carl
Subject: Re: Constant width grid
Date: 12 Jul 2006 17:05:00
Message: <web.44b5639be4538ab670dc520d0@news.povray.org>
Here is my latest try...

However you can now tell the grid lines have height.  I have another idea
but I'll discuss that over at "Re: TRON Game Grid..." in povray.newusers.


Post a reply to this message


Attachments:
Download 'test1.png' (75 KB)

Preview of image 'test1.png'
test1.png


 

<<< Previous 10 Messages Goto Initial 10 Messages

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.