BMFont: Padding and spacing errors
Hi,
There seem to be a couple of bugs with the padding and spacing options.
The spacing options seems reversed - if I leave a 1 between B and C and leave a 0 between A and C then I am left with Y spacing instead of X spacing, and vice versa.
The padding seems slightly odd too - if I opt to have 1 padding to the left, I end up with two pixels' worth of padding. Also I have had some characters split over the right edge of the texture when using x padding without any x spacing.
Additionally, the default spacing options of 1,1 seem to bleed over to the far edges of the bitmap, instead of offsetting everything in by 1 pixel. This could be a problem for renderers that can't repeat their UVs.
Just thought I'd let you know about these. Thanks :)
Alex
Which version are you using? I recently fixed a problem with the padding/spacing that seems to be what you're describing. Check out version 1.9b.
AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game
I tested the spacing, and you're right, they are indeed reversed. I'll have to fix that in a future release. The other problems should have been fixed in 1.9b though.
The spacing doesn't bleed over to the far edges, however it does reserve space on the left and bottom edges of the texture, so that characters are always kept apart as configured. This doesn't cause a problem for renderers that don't repeat the UVs since the spacing isn't supposed to be rendered anyway, it's just empty pixels.
Thanks,
Andreas
The spacing doesn't bleed over to the far edges, however it does reserve space on the left and bottom edges of the texture, so that characters are always kept apart as configured. This doesn't cause a problem for renderers that don't repeat the UVs since the spacing isn't supposed to be rendered anyway, it's just empty pixels.
Thanks,
Andreas
AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game
OK, thanks. Ah, my point about the non-repeating UVs is just nit-picking really, but it means that characters being scaled using a filter (rather than being drawn at 1:1) will have bad edges if they're on the left- or top-most part of a texture, as it won't be possible to filter out to empty pixels along those edges. I don't know of any (well-written) situations where this could occur though, so as I say, it's not important.
Cheers
Alex
Cheers
Alex
Hi Alex,
I've uploaded BMFont 1.9c which fixes the bug you mentioned. Thanks once more one for letting me know.
Regards,
Andreas
I've uploaded BMFont 1.9c which fixes the bug you mentioned. Thanks once more one for letting me know.
Regards,
Andreas
AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement