POV-Ray : Newsgroups : povray.advanced-users : Need two things.. : Re: Need two things.. Server Time
8 Jul 2024 18:10:11 EDT (-0400)
  Re: Need two things..  
From: Mark Weyer
Date: 25 Feb 2008 09:50:00
Message: <web.47c2d45def771f4cfddaa4670@news.povray.org>
> > The six vertices are x,y,z,-x,-y,-z, possibly scaled by something.
> > If you want rounded edges, say with radius R,
> > then put spheres with radius R at each vertex, a cylinder with radius
> > R at each edge (or, to save code, a spheresweep
> >   x y (-x) (-y) x z y (-z) (-y) z (-x) (-z) x )
> > displace the triangle with vertices a,b,c by (a+b+c)*R/sqrt(3) (for
> > all applicable values of a b and c).
> > This assumes, that you do not need a solid die, i.e. your textures are
> > not transparent.
>
> Got to be solid, or at least mostly. I need to cave in a set of symbols,
> and lettering.

In that case replace the triangles with something solid.
The easiest would be an eight of an octahedron: For the triangle with
vertices a, b, and c this would be

  intersection {
    plane { -a 0 } plane { -b 0 } plane { -c 0 }
    plane { a+b+c 1/sqrt(3) }
    translate (a+b+c)*R/sqrt(3)
  }

Keep in mind, though, that carved dice are not considered fair.

Best,

  Mark Weyer


Post a reply to this message

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