[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] Optimised 1bit blitters

From: Michal Suchanek
Subject: Re: [PATCH] Optimised 1bit blitters
Date: Tue, 25 Aug 2009 16:06:43 +0200

2009/8/23 Robert Millan <address@hidden>:
> On Fri, Aug 21, 2009 at 05:33:30PM +0200, Vladimir 'phcoder' Serbinenko wrote:
>> +  for (j = 0; j < height; j++)
>> +    {
>> +      for (i = 0; i < width; i++)
>> +        {
> It's a bit odd, but GCC doesn't seem to optimize those in a single loop.  
> Could
> you use "i = 0; i < height * width; i++" instead?  (for this and the other
> similar instances)
> I can't comment much on the rest of this patch, as my understanding of
> graphics is limited.  But please wait a few days before commit, hopefully
> someone else will review.

Well, this is not rocket science. You cache a function call which
would be done on every iteration otherwise. This is not feasible with
other bitmap types (except perhaps 8bit index->8bit index) because
they use many more colours.

How well tested is this? There are quite a few blitters and some may
not be ever used in current code.

The comment above the blend functions should probably not say they are
replace blitters.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]