PDA

View Full Version : Mirroring an image...



HopeDagger
23-05-2003, 07:49 PM
I'm currently programming a side-scrolling game using DelphiX (SpriteEngine, to be precise), and all of my current graphics only face in one direction. Must I go and flip each image manually and save it, or is there a way to do this at runtime? I'd imagine that since even Paint can flip images, DelphiX should be able to. It's just a question of how. :)

Thanks!

Traveler
26-05-2003, 07:32 AM
Hmmm didn't we had this question before... :roll:

But anyway, using scanline you most likely can come up with a horizontal/vertical flip of your images. But I would not recommend this procedure. In the end your only advantage is diskspace. I'd say draw your images in a painting program like Paint shop pro and flip em in there.
It will save you lots of time...

Alimonster
05-06-2003, 03:03 PM
DirectDraw provides a way to mirror images, but I can't remember what it is at the moment. I'll have a rummage around when I get home and will try to let you know.

But, well, flipping 'em in Paintshop beforehand works as well.

Useless Hacker
05-06-2003, 08:26 PM
I think in DirectX you can just switch the Left/Right and Top/Bottom coordiantes of the rectangle to flip vertically or horizonally. I don't think DelphiX allows this though.