Replies: 4 comments 4 replies
-
Your generated distance field looks completely off, it's surprising to me that it even produces the correct shape. I would suggest comparing your code with the reference implementation. |
Beta Was this translation helpful? Give feedback.
-
Could you please point us to the direct msdf implementation? Just didn't find it in your repo. |
Beta Was this translation helpful? Give feedback.
-
@Chlumsky |
Beta Was this translation helpful? Give feedback.
-
@Chlumsky float d = median(s.r, s.g, s.b) - 0.5; Thanks in advance. |
Beta Was this translation helpful? Give feedback.
-
Hi!
I'm trying to implement your direct MSDF algorithm using the "Shape Decomposition for Multi-channel
Distance Fields" paper, p. 4.4.
I've generated the following MSDF 64x64 pixels texture:
Also I'm using the following HLSL shader to reconstruct glyph from MSDF texture:
I'm just changed here
mix
tolerp
because it is the analog from HLSL.The result is the following:
As you probably can see the corners are not very sharp (and it is 64x64, not even 32x32 pixels texture).
I understand that without code review it may be hard to tell, but couldn't you probably point me where have I made mistake(s)?
Thanks in advance.
Beta Was this translation helpful? Give feedback.
All reactions