POV-Ray : Newsgroups : povray.binaries.utilities : postscript/pdf to POVRay prism : Re: postscript/pdf to POVRay prism Server Time
29 Apr 2024 20:52:19 EDT (-0400)
  Re: postscript/pdf to POVRay prism  
From: Ross Martin
Date: 19 Mar 2003 00:17:36
Message: <3E77FD38.5060104@ross.interwrx.com>
Hmmm.  I'm not sure I understand, but I'll answer what I think
you're asking.  One of the main reasons I made this code was
to allow LaTeX-generated text in POVRay.

First, a "prism" is a generalization of a polygon that allows
curves (not just straight sides) and is extruded into the third
dimension.  So I think this is what you want when you say you want
a "polygon".

Second, I'm not sure what you mean by an "outline".  You mean you
add something surrounding the text?  If it is just straight lines, you
could create it in LaTeX using the \hrule and \vrule or other commands,
and then this should appear in the PDF produced by pdflatex, and it
should then appear in the final POV file.  If it is a more complicated
"outline", you could perhaps create it in xfig, do your latex text in
xfig, export in pstex and pstex_t format, and then process through
pdflatex to achieve the desired result.  You could also get the same
effect by writing just your text in pdflatex and then adding a
"outline" directly in the povray source after the conversion.

If by "outline" you mean that you do something that looks like a
modification of the font, how you would do that would depend entirely on
the modification.  I think "outline fonts" is a name for fonts with a 3D
effect.  Of course, with POVRay you actually have 3D, so simulated 3D
using outlining would seem to be a bit strange when you have much
better real 3D available.

The code I made only converts objects that are actually drawn in the
postscript.  There is no way to add hints for how the object dimensions
should affect placement of other objects.  Perhaps something like this
could be added and might be a good idea.  Perhaps not.  I'd have to
think about it.  Don't expect anything soon.

I hope I've answered some of your questions, but if not please ask again
with more detail and perhaps an example.

Ross


Mark Weyer wrote:
>> I wrote the attached utility to convert vector-type (not bitmapped)
>> postscript/pdf files into POVRay prisms.  It works under Linux.
>> The first step is to "flatten" the postscript to a standard form
>> using the pstoedit package (available separately).  Then you run my
>> perl script to convert the "flattened" postscript into Prism statements.
> 
>  > [...]
> 
>> I hope you find it useful!
> 
> 
> I deem it very useful. So far I used bitmaps for importing LaTeX into
> povray. I would gladly convert to eps2pov, but there are problems:
>  - I would need polygons instead of prisms.
>  - I put an outline around the text using intermediate processing of
>    bitmaps. Is it possible to amend your script with an option to
>    follow the vector image with some distance?
> Unfortunately I know neither perl nor the flattened postscript.
> 
>


Post a reply to this message

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