POV-Ray : Newsgroups : povray.newusers : map a prism onto a sphere : Re: map a prism onto a sphere Server Time
28 Jul 2024 18:25:18 EDT (-0400)
  Re: map a prism onto a sphere  
From: Tim Attwood
Date: 27 Feb 2008 20:00:52
Message: <47c607c4@news.povray.org>
> I want to map a prism with n vertices, height_1=0 and height_2=0.001 onto 
> the
> surface of a sphere. Then I want to create the intersection of the sphere 
> and
> the mapped prism so that only the prism is visible. Can anybody help me?

This sort of shape probably could be achieved by
turning your prism into a height_field, then using
the HF_Sphere macro from shapes.inc to map the
height_field to the spherical mesh. You could then
use CSG to isolate the prism portion.

To turn a prism into a height_field image you can
set up an orthographic camera and use a gradient
pigment that fades from black to white with a
ambient 1 finish.


Post a reply to this message

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