[Papervision3D] TrueType Parser + Font3D = Runtime Font Loading
Mark Barcinski
barcinski at gmail.com
Thu Jan 1 09:51:44 PST 2009
That's great,
Thanks James!
On Dec 30, 2008, at 12:57 PM, James wrote:
> Hi Mark,
>
> You are welcome to use any of the code you see fit.
>
> I'll be working on the font library as time allows.
> Hopefully there will be working code by the end of January.
>
>
> Regards,
> James
>
> Mark Barcinski wrote:
>>
>> James Thanks!
>>
>> This is fantastic!!!!!!!
>> I was planing to do this for a long time, never found the time to
>> do it though. I hope you don't mind if your code finds it's way
>> into papervision.
>>
>> I'm also very excited about your leaner fornt parsing lib, any
>> hints on when it will be ready ? :)
>>
>>
>> speedok,
>>
>>> The conversion etc. will be done real time right? Using it the
>>> 'old' way
>>> with the font creator wouldn't that be faster ?
>>
>> It's the convenience that really matters, you can just use any font
>> you've got and see how it looks in your scene without the painful
>> process of font class creation.
>>
>>
>> Great work and thanks for sharing!
>>
>>
>>
>> On Dec 28, 2008, at 7:23 PM, James wrote:
>>
>>> Hey speedok,
>>>> Guess it's handy in the pv3d library then or is it only the way
>>>> you are
>>>> handeling the fonts ?
>>> If the char passed to VectorLetter3D does not exist in the font,
>>> Flash throws an error due to a null object reference.
>>> This happens for any font.
>>>> The conversion etc. will be done real time right? Using it the
>>>> 'old' way
>>>> with the font creator wouldn't that be faster ?
>>> Yes, the font is generated during runtime.
>>> For most circumstances it would be best to use a font that has
>>> already been converted to vector commands.
>>> Parsing a font file takes more time and memory than using a
>>> compiled font.
>>>
>>> I did this more because I already had the necessary pieces and
>>> just needed to stick them together than anything else.
>>>
>>>
>>> Thanks,
>>> James Hight
>>>
>>>
>>>
>>> speedok wrote:
>>>>
>>>> Aloha James,
>>>>
>>>> Good stuff !
>>>>
>>>> just wondering you wrote:
>>>> I did make a small change to the Papervision3D library. Some of
>>>> the font
>>>> files do not have a complete character set. This can cause
>>>> VectorLetter3D to
>>>> choke.
>>>>
>>>> -> Guess it's handy in the pv3d library then or is it only the
>>>> way you are
>>>> handeling the fonts ?
>>>>
>>>> The conversion etc. will be done real time right? Using it the
>>>> 'old' way
>>>> with the font creator wouldn't that be faster ?
>>>>
>>>> Anyway, real nice work and thanks for the share !
>>>>
>>>>
>>>>
>>>>
>>>> In org.papervision3d.typography.VectorLetter3D, around line 40 I
>>>> added:
>>>>
>>>>
>>>> James-203 wrote:
>>>>
>>>>> Hey all,
>>>>>
>>>>> I've been messing with fonts for another project and thought I'd
>>>>> try
>>>>> retasking some of the code to create Font3D objects from
>>>>> TrueType font
>>>>> files.
>>>>> Use is straight forward. Pass the font file ByteArray to
>>>>> Font3DLoader.load and it generates a Font3D object.
>>>>>
>>>>> var font3D:Font3D = Font3DLoader.load(trueTypeByteArray);
>>>>>
>>>>> You can see a demo here: http://labs.zavoo.com/?p=105
>>>>> Source code is available here:
>>>>> http://labs.zavoo.com/content/flex/DynamicFont3D/srcview/
>>>>> index.html
>>>>>
>>>>> I did add a check to VectorLetter3D.getLetterFromFont(). Not all
>>>>> fonts
>>>>> have a complete set of characters.
>>>>>
>>>>> if (_font.motifs.hasOwnProperty(_char)) {
>>>>> createVertices(_font.motifs[_char]);
>>>>> }
>>>>>
>>>>>
>>>>> Regards,
>>>>> James Hight
>>>>>
>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> Papervision3D mailing list
>>>>> Papervision3D at osflash.org
>>>>> http://osflash.org/mailman/listinfo/papervision3d_osflash.org
>>>>>
>>>>>
>>>>>
>>>>
>>>
>>> _______________________________________________
>>> Papervision3D mailing list
>>> Papervision3D at osflash.org
>>> http://osflash.org/mailman/listinfo/papervision3d_osflash.org
>>
>>
>> _______________________________________________
>> Papervision3D mailing list
>> Papervision3D at osflash.org
>> http://osflash.org/mailman/listinfo/papervision3d_osflash.org
>>
>
> _______________________________________________
> Papervision3D mailing list
> Papervision3D at osflash.org
> http://osflash.org/mailman/listinfo/papervision3d_osflash.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://osflash.org/pipermail/papervision3d_osflash.org/attachments/20090101/6f354045/attachment.html>
More information about the Papervision3D
mailing list