Hi,
I test this example of shader (C64colorshader):
// --------------------------------- //
// Project: C64izer
// Start: Tuesday, March 25, 2008
// IDE Version: 5.212
LOADBMP "test.png"
X_LOADSHADER(0, "", "C64izer.frag")
DRAWRECT 0,0,64,64,RGB(0,255,0)
DRAWRECT 0,0,32,32,RGB(0,0,255)
DRAWRECT 32,32,32,32,RGB(255,255,255)
PRINT "C64", 8,8
GRABSPRITE 0,0,0,64,64
// C64izeOld()
WHILE TRUE
ROTOZOOMSPRITE 0, 140,100, GETTIMERALL()/20, SIN(GETTIMERALL()/37)+1
C64ize()
SHOWSCREEN
WEND
FUNCTION C64ize:
// Grab the 320x240 image from screen
GRABSPRITE 1000, 0,0, 320,240
// Make smooth downscaling for better quality
SMOOTHSHADING TRUE
// Set the C64 color shader
X_SETSHADER 0
// draw the sprite 160x240 with C64 colors
STRETCHSPRITE 1000, 0,0,160,240
// unlink the shader - we're done
X_SETSHADER -1
// grab the image 160x240
GRABSPRITE 1000, 0,0,160,240
// make hard pixels for final output
SMOOTHSHADING FALSE
// stretch by factors 4x2 -> C64 has 2 neighbored pixels of same color
STRETCHSPRITE 1000,0,0,640,480
ENDFUNCTION
But if i delete all shader command the result it's the same, it's the STRETCHSPRITE command which has the effect C64 style!
I test with other .frag but the result don't change.
I would like to get the 2D effects (on sprites) as:
- Black / White (greyscale)
- Distortion
etc.
It's possible? and how?