Re: [ft-devel] Problem with Postscript Hint

2011-05-03 Thread Werner LEMBERG

> Question for the FT developers : why was this seed calculation
> implemented this way ? And not e.g. a fixed start value associated
> with each FT_Face created ? That would make FT output reproducable
> (and testable for detecting regressions).

I have no idea. :-) Patches are welcome.  Up to now I've never seen a
real PS font which actually uses random numbers for defining its
shape, so this is really a minor issue, necessary only to test the CFF
`random' operator (and similar stuff in other PS flavours).  BTW, if
you have such a font I would be glad if you can send it to me offline
for my font test collection.


Werner

___
Freetype-devel mailing list
Freetype-devel@nongnu.org
https://lists.nongnu.org/mailman/listinfo/freetype-devel


Re: [ft-devel] Problem with Postscript Hint

2011-05-03 Thread Werner LEMBERG

> I find the random generator, but it can’t explain what I’m
> experiencing.

Have you read this comment in the description of FT_Library

  For multi-threading applications each thread should have its own
  FT_Library object.

and are you following the advice?


Werner
___
Freetype-devel mailing list
Freetype-devel@nongnu.org
https://lists.nongnu.org/mailman/listinfo/freetype-devel


Re: [ft-devel] Problem with Postscript Hint

2011-05-03 Thread PILLET Céline
Hi John,

Thanks a lot for your answer.
I find the random generator, but it can’t explain what I’m experiencing.

Celine.

De : freetype-devel-bounces+celine.pillet=tagginfo@nongnu.org 
[mailto:freetype-devel-bounces+celine.pillet=tagginfo@nongnu.org] De la 
part de John Tytgat
Envoyé : mardi 3 mai 2011 12:35
À : freetype-devel@nongnu.org
Objet : Re: [ft-devel] Problem with Postscript Hint

On 5/3/2011 9:52 AM, PILLET Céline wrote:
I have a problem with hints of PostScript fonts.
I create 2 consecutives bitmap with a postscript font, with a multithread 
program, and rendering differs slightly.
I don’t have this problem when I create bitmap without “hints”.
I don’t have this problem when I create bitmap with “hints”, in a single thread 
program.
Do you have an idea of ​​something that is not thread safe in the PostScript 
hints code?

If you mean 'PostScript font' = Type 1, CID or CFF font', search for 'seed' 
used for implementing a random generator.  This is calculated based on location 
of stack variable.  This *could* explain what you're experiencing but I'm not 
sure.

Question for the FT developers : why was this seed calculation implemented this 
way ? And not e.g. a fixed start value associated with each FT_Face created ? 
That would make FT output reproducable (and testable for detecting regressions).

John.
___
Freetype-devel mailing list
Freetype-devel@nongnu.org
https://lists.nongnu.org/mailman/listinfo/freetype-devel


Re: [ft-devel] Problem with Postscript Hint

2011-05-03 Thread John Tytgat

On 5/3/2011 9:52 AM, PILLET Céline wrote:


I have a problem with hints of PostScript fonts.

I create 2 consecutives bitmap with a postscript font, with a 
multithread program, and rendering differs slightly.


I don’t have this problem when I create bitmap without “hints”.

I don’t have this problem when I create bitmap with “hints”, in a 
single thread program.


Do you have an idea of ​​something that is not thread safe in the 
PostScript hints code?



If you mean 'PostScript font' = Type 1, CID or CFF font', search for 
'seed' used for implementing a random generator.  This is calculated 
based on location of stack variable.  This *could* explain what you're 
experiencing but I'm not sure.


Question for the FT developers : why was this seed calculation 
implemented this way ? And not e.g. a fixed start value associated with 
each FT_Face created ? That would make FT output reproducable (and 
testable for detecting regressions).


John.

___
Freetype-devel mailing list
Freetype-devel@nongnu.org
https://lists.nongnu.org/mailman/listinfo/freetype-devel


Re: [ft-devel] Use tt_face_get_name() in sfnt_get_ps_name()?

2011-05-03 Thread Werner LEMBERG

> If these difference is not so important, I propose to change
> sfnt_get_ps_name() to thin wrapper of tt_face_get_name().

Looks good.  If you don't notice adverse effects please commit.


Werner

___
Freetype-devel mailing list
Freetype-devel@nongnu.org
https://lists.nongnu.org/mailman/listinfo/freetype-devel


[ft-devel] Problem with Postscript Hint

2011-05-03 Thread PILLET Céline
Hello guys,

I have a problem with hints of PostScript fonts.
I create 2 consecutives bitmap with a postscript font, with a multithread 
program, and rendering differs slightly.
I don’t have this problem when I create bitmap without “hints”.
I don’t have this problem when I create bitmap with “hints”, in a single thread 
program.
Do you have an idea of ​​something that is not thread safe in the PostScript 
hints code?

Regards,

Céline.



___
Freetype-devel mailing list
Freetype-devel@nongnu.org
https://lists.nongnu.org/mailman/listinfo/freetype-devel