I found and focused a bug.
Red box should be purely dupplicated from left to right, on screen.
But a strange vertical offset is included and the blue box appears on the copy from left to right.
Inside GrabDrawingImage() arguments.
I get what I want by replacing value 0 on y argument with the value 16, what it is... reversing brain !
Strange behaviour also : the effective Y argument is changing if the Height argument is changed.
Best regards
Code: Select all
examinedesktops()
Initsprite()
Initkeyboard()
Openscreen(desktopwidth(0), desktopheight(0), 32, "", #pb_screen_smartsynchronization)
Createsprite(0, 16, 48, #pb_sprite_alphablending)
If startdrawing(spriteoutput(0) )
Drawingmode(#pb_2ddrawing_allchannels)
Box(0,0,16,32,rgba(159,0,0,255) ) ; red box area
Box(0,32,16,16,rgba(0,0,255,255) )
Grabdrawingimage(1,0,0,16,32) ; BUG does not match to the red box area
Stopdrawing()
Endif
Createsprite(1,16,32,#pb_sprite_alphablending)
If startdrawing(spriteoutput(1) )
Drawingmode(#pb_2ddrawing_allchannels)
Drawimage(imageid(1), 0,0)
Stopdrawing
Endif
Repeat
Delay(16)
Examinekeyboard()
Clearscreen(0)
Displaytransparentsprite(0,0,0)
Zoomsprite(0,64,192)
Displaytransparentsprite(1,65,0)
Zoomsprite(1,64,128)
Flipbuffers()
Until keyboardpushed(#pb_key_escape)