game programming and scrolling inside a window?

gizmomelb

New Member
Licensed User
Longtime User
hi all,

first time poster here, so please excuse if this is the wrong forum to post my question in. I'm working on a game idea where I was to have a large tiled background scrolling both horizontally and vertically inside a 'window'.

Now I'm an old C64 and Amiga programmer and the way we used to do this was by using 'tiles' and if we were scrolling right, then we'd read the tile values for the X and Y position in the map and then copy the tiles into the video ram (off screen of course) etc.

I'm a little lost at the moment with how to approach this on Android.. there don't appear to be any concepts of playfields or screens that I can see (other than loading the 'bitmap' as an image and then scrolling that around.. but that's a huge memory hog).

Also so far my attempts at scrolling have not been successful.

Lastly is there any way to measure how much CPU / Video time your game loop is taking to process? The old trick I used was set the border / background colour to something which would stand out, set it at the start of the vertical blank for screen update.. process all main game loop and then set the background / border colour to black when it had finished.. so you could see by how big the red bar was on screen when you were approaching the limit of what could be processed in each screen refresh.

Or is the concept of screen refresh not applicable on Android and LCD devices?

Sorry for being so 'old school' :)
 
Top