On 2/15/07, Sakur <[EMAIL PROTECTED]> wrote:

 Hi,All:
    Recently,when I tested my directfb application (through some special
test engine),I encountered a assert fail located in dfb_gfxcard_blit(
gfxcard.c)-->>>D_ASSERT( rect->x < state->source->width )
    In my test program,a source rectangle
(x:INT_MAX,y:INT_MAX,w:INT_MAX,h:INT_MAX) was passed into
IDirectFBSurface->Blit function,then,the assert error  crashed the
program.Theoretically, this rectangle should never be intersected with any
surface area. But it passed the intersect check in IDirectFBSurface_Blit
,(function *dfb_rectangle_intersect* return true), therefore caused the
assert in dfb_gfx_blit. The reason why it could pass is that INT_MAX+INT_MAX
= -2 (see dfb_rectangle_intersect implementation). Am I missed something
that this issue is already known or anyone help me confirm this? Thanks


This sounds like a valid error... the numbers usually handled in coordinate
spaces in directfb are so small that this hadn't been seen before.

The problem is that the rectangle is invalid because it can't be converted
into a DFBRegion -- while the top-left corner is in the valid coordinate
space (INT_MAX, INT_MAX), the bottom-right corner is outside that space
(actually, any size rectangle other than 0,0 would be invalid here).
_______________________________________________
directfb-dev mailing list
[email protected]
http://mail.directfb.org/cgi-bin/mailman/listinfo/directfb-dev

Reply via email to