program ShowCompressedImage;
@use "crtc"
@use "memory"
@use "system"
@use "text"
@use "compression"
/*
	Loads a compressed TRSE image (located in the resources/images folder" for 256x240 4-colour mode

*/
 
 
// Automatically export 256x240 4-color image

@export "resources/images/trse.flf" "resources/images/trse.bin" 256

var  
// Include the exported image data + palette
	image : incbin("resources/images/trse.bin") compressed;
	
	
begin
	Crtc::SetMode(Crtc::mode_4_color);
	Crtc::EnableVRAM();
	Crtc::SetPalette(0,Crtc::black);
	Crtc::SetPalette(1,Crtc::yellow);
	Crtc::SetPalette(2,Crtc::green);
	Crtc::SetPalette(3,Crtc::blue);
	// Copy to VRAM
	Compression::Decompress(#image, $8000);

	loop();	

end.
