You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RasterImage is now not seralizeable and backed by Vec storage. Add a new struct SharedRasterImage that allows serializeing. This can be constructed from RasterImage. This introduces some more copying but I think the tradeoff is ok. Newly introduced copies are for favicon response to the embedder and EmbedderNotifications.
Testing: Should not change functionality, so covered by existing tests. Fixes: #39626 and related issues.
The reason will be displayed to describe this comment to others. Learn more.
I would leave all of these types as RasterImage but implement a From<SharedRasterImage> for RasterImage and just call into() when filling these fields.
Add a new struct `SharedRasterImage` that allows serializeing. This can
be constructed from RasterImage.
Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
mrobinson
changed the title
net: Disallow RasterImage to be serialized and introduce SharedRasterImage
net: Do not implement Serialize/Deserialize for RasterImage and introduce`SharedRasterImageNov 7, 2025
The reason will be displayed to describe this comment to others. Learn more.
Let's give this a shot. If we notice a large performance regression we can revert it. I think we have eliminated a few copies in the image code already, so I'm pretty sure this is okay.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
RasterImage is now not seralizeable and backed by Vec storage. Add a new struct
SharedRasterImagethat allows serializeing. This can be constructed from RasterImage. This introduces some more copying but I think the tradeoff is ok. Newly introduced copies are for favicon response to the embedder and EmbedderNotifications.Testing: Should not change functionality, so covered by existing tests.
Fixes: #39626 and related issues.