[interfacekit] Re: Clipping - what to do, what to do?

Gabe Yoder <gyoder@xxxxxxxxxxx> wrote:
> >    We could do it the "hard" way, by checking every pixel if it is 
> > in the
> >    visible region, by invoking BRegion::Contains(pt), but this will 
> > be
> >    overkilling for the CPU. This has the advantage that it requires 
> > no
> >    additional memory.
> Working at the pixel level is definitely overworking the CPU.  It is 
> a 
> relatively simple procedure to transform figures into lines and then 
> clip 
> each of the lines.

It's really simple for rectangular areas, but how else would you handle 
arbitrary shapes? With rectangular areas and transparency?

Bye,
   Axel.


Other related posts: