[SDL] Re: extension for 2D with DRI

Pierre Phaneuf pp at ludusdesign.com
Sun Apr 16 12:10:55 PDT 2000


Mattias Engdegård wrote:

> > I do not know for conversion between 50 and 60 Hz, but I know for a fact
> > that conversion between 24 fps film movies and North American 60 Hz
> > television is done by doubling frames. Yes, the "cheap and bad" method.
> 
> Cheap but not bad. The large common divisor makes the period short.
> The usual 2:3-transfer alternates between 2 and 3 half-frames per film
> frame (according to the well-informed TV/video standards FAQ,
> http://www.bawue.de/~agnus/FAQ_Video.text). For an analogy in computer
> graphics, think of a pattern dither: if you have a fine-grained, regular
> pattern, it looks like a solid colour from afar, but large, irregular
> patterns are more likely to show artifacts.

Darn, the link is in german and sure looks interesting!

But I know a bit about dithering, and you might also know that some
types of dithering uses random patterns so that it looks more natural
(the regular patterns of dithering sometimes forms higher-level
artifacts, often looking like bands). Not convinced yet.

> [Quake example]
> > And when you look at
> > the action, it is okay and looks pretty regular, doesn't it?
> 
> No doubt so, but I believe 3D games are more resistant to it. I will try
> to construct a 2D demo where the effect can be seen, to convince myself
> and any heretics :-)

Yes, I'd be happy to see a demo! Well, actually, Quadra (our game, see
the URL at the bottom for more info) *does* slips duplicated frames
onces in a while in a semi-random manner, at high framerates (when you
get over 100 fps, which is the limit of the game clock, it fills up with
duplicate frames). In 8 bit PseudoColor on my P225 and with a high vsync
rate on my monitor (I have a "Professionnal Serie" ViewSonic monitor,
quite good, I recommend them very much), it happens and can't really
tell without the framerate indicator. The main animation consist of a 2D
block that falls down the screen in a smooth manner.

> > And if it uses PIO to do the
> > transfer and that the transfer takes longer than the vertical retrace,
> > then even if it *is* synchronized to the vertical retrace, you'll see
> > artefacts.
> 
> Yes, possibly even worse since the tearing will occur at the same scan line
> every time. This was not what happened on the Ultra, so its blitting isn't
> synchronized.

PIO transfers are done by the CPU, and because of scheduling, the
tearing doesn't occur at the same scan line. Doesn't prove that the
blitting isn't synchronized, it could still be. It *should* happen
"around" the same scan line, plus or minus 50 lines I'd say, with
possibly larger pathological variations once in a while.

-- 
Pierre Phaneuf
http://ludusdesign.com/



More information about the SDL mailing list