I have an application which allows users to configure the interior of a room and then also save/load the configuration.
When saving the room a screenshot is taken, and rescaled to different dimensions, to serve as thumbnail, preview… etc.
For the windows version of this application I tried to use the System.drawing functionalitys.
This works fine in Editor, the Images Get scaled and croped as desired.
Now the Build Version crashes with a TypeLoadException for a BufferOverflowException, log attatched.
I dont really get it why it’s working in the Editor and not working in the build, Do I Need some native librarys that are not present in the Build or what am I missing here?
Or does someone have a possibility to work with images on Windows that is working?
The Console tells this:
TypeLoadException: Could not load type ’System.IO.InternalBufferOverflowException’ from assmbly ‘System.Drawing’.
System.Drawing.Image.FromFile(System.String filename, Boolean useEmbeddedColorManagement) System.Drawing.FromFile(System.String filename)
ImageResizeWindows.ScaleAndCropImage(Int32 width, Int32 height, System.String sourcePath, System.String destinationPath) (at … buntch of own classes using this code)