Blitting small surfaces

Hi,

I’m writing a program that fills a surface with a
bunch of small 8x8 pixel squares to form sort of a map…

Like this:

XXXXXXXXXXX
XXXXXXXXXXX
XXXXXXXXXXX
XXXXXXXXXXX
XXXXXXXXXXX
XXXXXXXXXXX
XXXXXXXXXXX

Where that whole big square is the surface and the X’s are
the 8x8 tiles I’m copying into it.

Each X is a 8x8 tile like this:

PPPPPPPP
PPPPPPPP
PPPPPPPP
PPPPPPPP
PPPPPPPP
PPPPPPPP
PPPPPPPP
PPPPPPPP

^^^^ 8 x 8

The depth is 8 bits.

Anyhow…copying these small tiles to the big surface takes a long
and I’m wondering if I made each one a surface and called the
blit function for each tile copy to the large surface…if it would
be an inefficient means of copying them…

I mean…the size of a SDL_Surface struct is like 60 bytes (with no
data)
and the pixels alone in one tile is like 64 bytes…Do you see what I
mean?

How would you recommend that I go about copying these tiles to the
screen?

o A custom blit?
o copy line by line with memcpy?
o ?

I don’t know…

Any ideas? Speed is the point here…

by the way…would it be a good idea for SDL to have platform
independant
MIDI capability? I mean…maybe a sequencer to the MIDI device? Or
possibly
Timidity code for soft synthesis? I know v0.8a has MOD support and
that’s cool
or do you know of any software to translate MIDI files to MOD format?

Thanks,

Paul Lowe
xpaull at ultraviolet.org