fix(io): crash when deserialising a empty image
Description
crash when deserialising an empty image.
Steps to reproduce
Serialize an empty image (pixel format will be UNKNOW & size is 0) On deserialize when calling the image->resize() function it will assert on the number of components.
Proposal
Do not call the resize() if either size is 0 or PixelFormat is unknown.
Functional specifications
- No changes
Technical specifications
- add this use case on unit test
Test plan
- add the new use case in unit test, and test it ofc.