POV-Ray : Newsgroups : povray.general : help w/ creating a hill : Re: help w/ creating a hill Server Time
12 Aug 2024 05:22:25 EDT (-0400)
  Re: help w/ creating a hill  
From: Ken
Date: 28 Mar 1999 05:17:15
Message: <36FE009B.5F295536@pacbell.net>
William Drown wrote:
> 
> Hello.
>   I am creating a scene w/ a castle on top of a hill and surrounded by a
> wall at the bottom. The hill consists of a merge csg consisting of the
> following component:
>        1 box that forms the top and main body of the hill
>         4 cones, 1 centered on each corner, w/ 0 radius on top
>         An inclined plane on each side to fill in the gaps
> I need help creating the inclined plane. I already put together the box
> w/ the cones, and the basic picture is already looking good. When I
> tried a prism object, w/ linear splines, it came out awful. I checked
> the docs for anything creating an inclined plane or wedge shape, but I
> can't find anything that does what i want. Please help me find a
> solution, cause it is very aggravating to be so close and yet so far.
> 
>                     Bill Drown


 There is one little trick you can try that might be to your liking.
Use a box or superellipsoid object scaled to length. Stand it up at
an appropriate angle and scale it verticaly. Then rotate it back
into a near flat position. You will find your once square box is now
sloped.

Untested example:

box{-.5,.5
 scale < 10, 2.5, 5.0 >
  rotate 45*z
   scale < 1.0, 0.75, 1.0 >
    rotate 45*-z
}


Besides this hack using primitives there is really nothing you can't
do with csg operations if you work hard enough at it or the much
easier approach would be, as Bob said, by using height fields in the
first place.

  Make your own height field map for a ramp by taking a white flat
box and lay it up against a black plane. Give the box a finish with
ambient 0 and diffuse 0.6 - 1 . Place a camera pointing straight at
at it with a light source back as far as the camera but way off to
one side of the box. You will have one side of the box lit more
brightly than the other and this brightness diffrence if used as
an image for a HF object will give you a sloping ramp shape.


Or you could just cheat. Take a box the right size, tilt it, and then
bury the uneeded parts into the ground. Who's going to know ?

-- 
Ken Tyler

mailto://tylereng@pacbell.net


Post a reply to this message

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