[vtk-developers] Re: vtkVectorText beyond ASCII - solution
Sean McBride
sean at rogue-research.com
Thu Jan 10 10:24:30 EST 2008
On 1/10/08 5:58 AM, Michail Vidiassov said:
>> I'm not sure about this 'point problem' though.....
>
>When a text string is rendered vtkVectorText advances
>0.4 horizontally for a space and
>1.4 vertically for a new line.
>It assumes certain font size.
>FreeType measures fonts in points.
>FTGL uses OpenGL units.
>I do not understand what point size to use.
>There is a couple of #defined constants in the font
>generating utility (point size and the factor the resulting coordinates
>are devided by) I have set somehow, but the resulting text is smaller then
>vtkVectorText.
>It would be nice to know what the result is supposed to be like.
>(For example - "vector glyph in vtk must be at most 1.2 units high" or
> "one point equals 0.1 vtk unit").
>Thus the question about relation between point size, OpenGL and VTK units.
I see. Alas, I have no idea. :)
>(Offtopic.
>Such questions are typical for an occasional OpenSource coder, who
>makes changes in other's code while having only a wague ideas on what that
>code is supposed to do, to say nothing about how...
Maybe no one knows how this class really works anymore. Looking at:
<http://public.kitware.com/cgi-bin/viewcvs.cgi/Hybrid/vtkVectorText.cxx?
rev=1.36&view=log>
Indicates that not much has changed in years. Which is pretty much what
Will was alluding to I think. :)
>As to the vtkVectorText performance issue - I would like to know what were
>the reasons to make it as ugly as it is ;)
>On the plus side - if the polygon count in the existing vtkVectorText
>glyphs is low (are they hand-crafted?), then after eliminating on-the fly
>parsing the existing set will be really nice - small, fast, backwards
>compatible and covering 90% of needs.
Assuming no one answers about the 'point problem', could you split your
changes so we can at least start applying some of your work to cvs? I
would be willing to help you test and commit it.
--
____________________________________________________________
Sean McBride, B. Eng sean at rogue-research.com
Rogue Research www.rogue-research.com
Mac Software Developer Montréal, Québec, Canada
More information about the vtk-developers
mailing list