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

duplicate embedded images #1864

Closed
nschloe opened this issue Nov 30, 2023 · 1 comment
Closed

duplicate embedded images #1864

nschloe opened this issue Nov 30, 2023 · 1 comment

Comments

@nschloe
Copy link

nschloe commented Nov 30, 2023

I frequently deal with SVGs with embedded raster images. They sometimes embed images more than once, even many times, e.g.

...
<image ns1:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAH8AAAAbAQAAAAB9o23yAAAADUlEQVR42mMYBcMFAAABywABVwMJ1QAAAABJRU5ErkJggg==" id="V" width="127" height="27" x="0" y="0"/>
<image ns1:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAH8AAAAdAQAAAACr+o7vAAAADUlEQVR42mMYBSMHAAAB7QABf4wHzwAAAABJRU5ErkJggg==" id="X" width="127" height="29" x="0" y="0"/>
...

In my case they all appear in the <defs> section, so deduplicating that would probably help.

The data between those could be shared.

@nschloe
Copy link
Author

nschloe commented Nov 30, 2023

Duplicate of #802.

@nschloe nschloe closed this as completed Nov 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant