[coyotos-dev] Rendering vs. Windows
nadiasvertex at gmail.com
Tue Aug 26 13:44:59 CDT 2008
On Tue, Aug 26, 2008 at 1:51 PM, Jonathan S. Shapiro <shap at eros-os.com> wrote:
> Separate from rendering is "hit detection". If a mouse click is
> processed at a given bit position, which window (really, in our design,
> which layer) gets it?
> I am of the opinion that the best realizable solution is as follows:
> If a click occurs at a given screen bit position P, the click should
> be delivered to the uppermost layer (LGC) whose bit at the
> corresponding position has a transparency value greater than some
> threshold value T.
I believe gl has a "hit" buffer. That is, each application's drawing
could be tagged with an id value, and then just check the buffer at
that pixel location for the last writer. This works fine if z-order
is respected in the buffer, and is also a reasonably simple extension
to z-buffering in software.
More information about the coyotos-dev