Question About Vektar's Code


blakespot

Still Fresh
Joined
Jul 19, 2006
Messages
90
I'm quite intrigued w/ the GP2X. I've spent much of my free time over the last week filling my new unit. Good stuff.

I quite enjoy Vektar, the game. I am a developer and had some questions. I think DZZ reads these forums.

- Does the backscroller or other part of the game use the GP2X's blitter, or is it software blits?
- Does the GP2X have sprite support, or is that software?
- How hard, with the avail dev kit, would it be to write a Hello World app (I assume I can use C) and just fill the screen with a solid color. Would that be a long app as far as lines of code?
- Is the blitter well documented? On the web somewhere?

Thanks!




blakespot
 
Dev corner ... that way ==>

We mere mortals can't answer those questions here.
 
blakespot posted on Jul 27 2006 at 06:57 AM said:
I'm quite intrigued w/ the GP2X. I've spent much of my free time over the last week filling my new unit. Good stuff.

I quite enjoy Vektar, the game. I am a developer and had some questions. I think DZZ reads these forums.

- Does the backscroller or other part of the game use the GP2X's blitter, or is it software blits?
- Does the GP2X have sprite support, or is that software?
- How hard, with the avail dev kit, would it be to write a Hello World app (I assume I can use C) and just fill the screen with a solid color. Would that be a long app as far as lines of code?
- Is the blitter well documented? On the web somewhere?

Thanks!




blakespot
I cant answer the first question but the reminder I give my best shot.

2) If you are talking about something similar to the GBA OAM, then no.
3) Really easy (there are several devkits so the difficulty in setting one up may vary)
4) I only use SDL which uses the blitter but nubie has links to the hardware documentation of the GP2X in his signature.
 
Last edited by a moderator:
blakespot posted on Jul 27 2006 at 11:57 AM said:
I quite enjoy Vektar, the game.
Thank you!
I am a developer and had some questions. I think DZZ reads these forums.
Rather too much I'm afraid.
- Does the backscroller or other part of the game use the GP2X's blitter, or is it software blits?
Vektar does not use the hardware blitter. It draws its graphics mostly by drawing lines, which the blitter does not help with.
- Does the GP2X have sprite support, or is that software?
The hardware blitter gives some degree of sprite support, if your needs are not too complicated. Using the blitter is faster than even the best software solution, but the difference in speed can be made pretty small because the memory bandwidth becomes a bottleneck at some point. However, using the blitter saves your data cache and allows you to do a little bit of work simultaneously if you code it carefully.
- How hard, with the avail dev kit, would it be to write a Hello World app (I assume I can use C) and just fill the screen with a solid color. Would that be a long app as far as lines of code?
There are several approaches to this. The simplest is to use a library called SDL which is what most people use to develop gp2x applications. There is a simple example SDL program that you can start with. Going that route I would say that a developer could get everything installed and have a modified version of the example that fills the screen with the color of your choice in an evening's worth of effort. Most of that is figuring stuff out of course, getting used to building programs, studying SDL a little bit, and so on. It might take two evenings if the environment is very different from what you're used to.

A good site with info about this stuff is http://wiki.gp2x.org

Besides SDL there are other libraries you can use -- I believe there is Allegro and now there is a commercial library called Edge available. Or you can just go without a big library and write to screen memory yourself. If you want to go that route you can find rlyeh's minlib to use as a starting point or read my article series on this site about "Gp2x Demo Development", which will be of interest if you if you care about the low level details.
- Is the blitter well documented? On the web somewhere?
Not really. When I was curious about the blitter I searched way back in time on this site to find conversations of the guys who first figured out how to use it, then referred to the code in Paeryn's hardware-accelerated version of SDL. You can figure out the basics of how to use it from that stuff. I'm not sure whether anybody has used all the features even yet though.
 
Last edited by a moderator:
Back
Top