 |
forums.ps2dev.org Homebrew PS2, PSP & PS3 Development Discussions
|
| View previous topic :: View next topic |
| Author |
Message |
the underminer
Joined: 03 Oct 2005 Posts: 124 Location: Netherlands
|
Posted: Tue Apr 18, 2006 4:01 am Post subject: very weird blitting problem |
|
|
There is this problem I can't solve and I started to think that lua just skipped a line. For testing, I tried to overwrite the image 'field' with itself. To do this, I first copied field to tempfield, then cleared field and blitted the copy to field again. The function TempRender shows me the contents of field. The first time TempRender is called, the field looks good and filled with color. The second time, only BufferX is visible. Frustrating! Can someone tell me why BufferX is [i/] and field isn't blitted or visible?
| Code: |
tempfield = field
TempRender()
field:clear()
field:blit(0,0,tempfield,0,0,480,256) -- this line has no effect at all
CameraPos[1] = CameraPos[1] - 1
FillBufferXLeft()
field:blit(0,0,BufferX,0,0,32,256)
TempRender() |
| Code: |
function TempRender()
screen:clear()
screen:fillRect(0, 0, 480, 272, skyblue)
screen:blit(0,0,field,0,0,480,256)
screen.flip()
System.sleep(1250)
end |
_________________ Behold! The Underminer got hold of a PSP |
|
| Back to top |
|
 |
the underminer
Joined: 03 Oct 2005 Posts: 124 Location: Netherlands
|
Posted: Wed Apr 19, 2006 6:22 pm Post subject: |
|
|
| Code: | | field:blit(0,0,field,0,0,448,256) | does work, but field:blit(32,0,field,0,0,448,256) doesn't. I guess the first parameter can't be positive? The field is 480x256 so there shouldn't be a problem(32+448=480).
This is very weird indeed.[/code] _________________ Behold! The Underminer got hold of a PSP |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|