Opened 6 years ago

Closed 6 years ago

#83 closed defect (fixed)

Export to Amstrad CPC fileformat crashed the application

Reported by: jenshermann72@… Owned by: pulkomandy
Priority: major Milestone: 2.6
Component: GrafX2 Version: 2.5
Keywords: Cc:

Description

Exporting an image to the Amstrad CPC fileformat crashes (sometimes) the application. It doesn't matter which size, but it matters the numbers of colors. If more than 16 Grafx2 become unstable / crashes. If restarting the app again and then loading recovered picture the application crashes again. That happens to version 2.3, 2.4 and 2.5.

Attachments (2)

nq3_full.gif (9.4 KB ) - added by jenshermann72@… 6 years ago.
all layers
nq3.gif (7.0 KB ) - added by jenshermann72@… 6 years ago.
all layers merged

Download all attachments as: .zip

Change History (10)

comment:1 by Thomas Bernard, 6 years ago

could you upload a sample image ? (in gif format ;)
and tell us which CPC format you tried so save to ?

by jenshermann72@…, 6 years ago

Attachment: nq3_full.gif added

all layers

by jenshermann72@…, 6 years ago

Attachment: nq3.gif added

all layers merged

comment:2 by jenshermann72@…, 6 years ago

Sure. I've uploaded two files which I did for the nq! music disc together with shining. One is the full layer version. I've realized an unstable app if I merged all layers together and saved it to the CPC version. The application crushed, no file was generated and my original file was destroyed.
Cheers,

Jens

comment:3 by Thomas Bernard, 6 years ago

I see that the pixel value are not checked :
https://gitlab.com/GrafX2/grafX2/blob/master/src/libraw2crtc.c#L34

So indeed to save to .cpc (SCR) format, you should first check that there is not pixel with color > 16.
That should be fixed, but anyway your picture can not be saved to that format unless you reduce it to 16color.

comment:4 by jenshermann72@…, 6 years ago

Resolution: fixed
Status: newclosed

Ok, that works. Thanks for the help.

comment:5 by PulkoMandy, 6 years ago

Resolution: fixed
Status: closedreopened

Still, it should not crash.

comment:6 by Thomas Bernard, 6 years ago

I have made some fixes but I need to rebase...

comment:8 by Thomas Bernard, 6 years ago

Resolution: fixed
Status: reopenedclosed

I think the crash should now be fixed

Note: See TracTickets for help on using tickets.