POV-Ray : Newsgroups : povray.newusers : forcing POVray to ignore degenerate cylinders : Re: forcing POVray to ignore degenerate cylinders Server Time
29 Jul 2024 10:23:09 EDT (-0400)
  Re: forcing POVray to ignore degenerate cylinders  
From: Christoph Hormann
Date: 12 Feb 2006 13:35:03
Message: <dsnv3t$s9e$1@chho.imagico.de>
shane wrote:
> howdyall,
> 
> is there still no way to force POVray to ignore degenerate cylinders
> altogether and keep parsing and rendering, instead of just stopping?

No.  If you don't want a cylinder don't put it in the scene.

> did a
> search and it seems this prob goes back to 2002. anyone anywhere ever do
> something about it?
> 
> basically it seems PYMOL generates a lot of degenerate cylinders when
> outputting molecular models to POVray and it's plain too difficult to weed
> them all out line by line.

You don't have to.  Simply replace any cylinder with a macro call like:

Cylinder(Pos1, Pos2, Radius)

instead of

cylinder { Pos1, Pos2, Radius }

and use a macro like the following to generate the cylinders:

#macro Cylinder(Pos1, Pos2, Radius)
   #if (vlength(Pos2-Pos1)>Radius*0.001)
     cylinder { Pos1, Pos2, Radius }
   #end
#end

Christoph

-- 
POV-Ray tutorials, include files, Landscape of the week:
http://www.imagico.de/ (Last updated 31 Oct. 2005)
MegaPOV with mechanics simulation: http://megapov.inetart.net/


Post a reply to this message

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