Skip to content
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

No implementation of LoadImageSvg #485

Open
rocktavious opened this issue Jan 19, 2025 · 1 comment
Open

No implementation of LoadImageSvg #485

rocktavious opened this issue Jan 19, 2025 · 1 comment

Comments

@rocktavious
Copy link
Contributor

rocktavious commented Jan 19, 2025

It looks like the core raylib library used to have LoadImageSvg but then was pulled out because the underlying library nanosvg is unsupported. It looks like you @gen2brain have https://github.com/gen2brain/svg to load svg's into golang Image structs. But its unclear to me how one would turn that back into a texture for raylib.

I'm trying to load SVG files as icons so that I can render them in the my UI. I understand that implementation of LoadImageSvg used to rasterize the SVG at a specific size and I intend to handle that but thats beside the point.

This feels like something everyone would want to do (load svg files) and it seems we have all the machinary needed to make it work in pure golang but i'm lacking the understanding of how to make the happen. Can someone here throw me a bone or can we consider adding this back to the library so its more turnkey?

@gen2brain
Copy link
Owner

LoadImageFromImage can be used to load Go image.Image. Hacking core library is not an option.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants