-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Padding support #76
Comments
I don't think this would be too difficult: once the SVG has been rasterised as a Pixmap, it could then be redrawn into a buffered Pixmap (buffered by the number of padding pixels required). But I'm wondering what need you have that can't be handled by the |
Almost less of a use case and more of a workaround for poorly exported assets. We have found on occasion that Figma, depending on how the vector is constructed, will sometimes export a SVG somewhat poorly which can result in a sort of sub-pixeling effect. Having the ability to add a 1-2px spacing around each icons accommodates for that. When drawing sprites to webgl for instance if the sub-pixeling is occurring you will see icons "bleeding" into one another just slightly. |
Am I right to say that Spritesmith's (Not saying you should switch to Spritesmith, just wondering if that's the functionality you want to duplicate.) |
@flother precisely! |
First off, excellent library, it has worked really well for us! One small need we have is actually applying a 1-2px padding around each icon. While this can be done at the SVG asset level we found it is a little easier to blanket apply it at the time of spritesheet generation. Current thought is a
--spacing=1
flag or similar that would apply padding around each asset for the defined value.The text was updated successfully, but these errors were encountered: