|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
I've been doing various things with conic-swept prisms, and I've been
getting some very unexpected results. I tried reducing my problem to a
simpler scene file, and though it did not come up with exactly the same
unexpected results as before, it's still not working as I expected. Here is
a simple example. With a normal perspective camera, it is a nice square
pyramid. With a directly overhead orthogonal view, however, the whole thing
appears green. Though I am not sure, from my previous experimentation I
believe that only the base is appearing, and not the walls of the pyramid,
similar to results one receives when using back-face culling with reversed
normals.
//camera {location <5, 7, 2> look_at <1,0,0>}
camera {orthographic location <0, 10, 0> look_at <0, 0, 0> up x*3 right z*4}
light_source {<5,5,5> rgb 1}
difference {
prism {
conic_sweep
linear_spline
0, 1, 5,
<-1, 1>, <1, 1>, <1, -1>, <-1, -1>, <-1, 1>
scale <1, -1, 1>
translate y*1
}
pigment {
gradient y
color_map {
[0.0 color <0, 1, 0> ]
[1 color <0, 0, 1> ]
}
scale y*.2
}
finish {ambient .5}
}
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Oops, don't ask why I put it in a difference, I was doing a more complicated
example before. Now that part can be deleted.
"clum" <nomail@nomail> wrote:
> I've been doing various things with conic-swept prisms, and I've been
> getting some very unexpected results. I tried reducing my problem to a
> simpler scene file, and though it did not come up with exactly the same
> unexpected results as before, it's still not working as I expected. Here is
> a simple example. With a normal perspective camera, it is a nice square
> pyramid. With a directly overhead orthogonal view, however, the whole thing
> appears green. Though I am not sure, from my previous experimentation I
> believe that only the base is appearing, and not the walls of the pyramid,
> similar to results one receives when using back-face culling with reversed
> normals.
>
> //camera {location <5, 7, 2> look_at <1,0,0>}
> camera {orthographic location <0, 10, 0> look_at <0, 0, 0> up x*3 right z*4}
> light_source {<5,5,5> rgb 1}
>
> difference {
> prism {
> conic_sweep
> linear_spline
> 0, 1, 5,
> <-1, 1>, <1, 1>, <1, -1>, <-1, -1>, <-1, 1>
> scale <1, -1, 1>
> translate y*1
> }
>
> pigment {
> gradient y
>
> color_map {
> [0.0 color <0, 1, 0> ]
> [1 color <0, 0, 1> ]
> }
> scale y*.2
> }
> finish {ambient .5}
> }
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"clum" <nomail@nomail> wrote in message
news:web.44eea9b5cc351d989bc721f00@news.povray.org...
> Oops, don't ask why I put it in a difference, I was doing a more
> complicated
> example before. Now that part can be deleted.
>
> "clum" <nomail@nomail> wrote:
>> I've been doing various things with conic-swept prisms, and I've been
>> getting some very unexpected results. I tried reducing my problem to a
>> simpler scene file, and though it did not come up with exactly the same
>> unexpected results as before, it's still not working as I expected. Here
>> is
>> a simple example. With a normal perspective camera, it is a nice square
>> pyramid. With a directly overhead orthogonal view, however, the whole
>> thing
>> appears green. Though I am not sure, from my previous experimentation I
>> believe that only the base is appearing, and not the walls of the
>> pyramid,
>> similar to results one receives when using back-face culling with
>> reversed
>> normals.
>>
>> //camera {location <5, 7, 2> look_at <1,0,0>}
>> camera {orthographic location <0, 10, 0> look_at <0, 0, 0> up x*3 right
>> z*4}
>> light_source {<5,5,5> rgb 1}
>>
>> difference {
>> prism {
>> conic_sweep
>> linear_spline
>> 0, 1, 5,
>> <-1, 1>, <1, 1>, <1, -1>, <-1, -1>, <-1, 1>
>> scale <1, -1, 1>
>> translate y*1
>> }
>>
>> pigment {
>> gradient y
>>
>> color_map {
>> [0.0 color <0, 1, 0> ]
>> [1 color <0, 0, 1> ]
>> }
>> scale y*.2
>> }
>> finish {ambient .5}
>> }
>
>
Hi Clum,
If you change the camera to
camera {orthographic location <0.0000001, 100, 0> look_at <0, 0, 0> up x*3
right z*4}
it should fix this particular problem (possibly not some of the others you
elude to).
I can't recall the exact reason for this problem, but it's to do with having
the camera directly over the look_at point, which I think used to raise an
error in earlier versions of POV-Ray. I think it's something to do with
divide-by-zero errors that arise quite a lot when calculating for that
particular condition.
Regards,
Chris B.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Thanks, that fixed all of my problems. I was trying to make an overhead 2-d
"map" of my scene, and all of the prisms weren't rendering correctly, but
now they are.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
|
|