Hi,

I was updating my local dri2.xml based on the latest dri2proto.h [1]
and I noticed that the DRI2 event BufferSwapComplete is too long to fit core protocol events.

The best I can calculate is
    sizeof(xDRI2BufferSwapComplete) == 34
which disagrees with
    #define sz_xDRI2BufferSwapComplete 32

I suppose if event_type would be a CARD8, it could fit where the padding is now and the length discrepancy would be fixed.

Any comments?

---

/* Excerpt from dri2proto.h */
typedef struct {
    CARD8 type;
    CARD8 pad;
    CARD16 sequenceNumber B16;
    CARD16 event_type B16;
    CARD32 drawable B32;
    CARD32 ust_hi B32;
    CARD32 ust_lo B32;
    CARD32 msc_hi B32;
    CARD32 msc_lo B32;
    CARD32 sbc_hi B32;
    CARD32 sbc_lo B32;
} xDRI2BufferSwapComplete;
#define sz_xDRI2BufferSwapComplete 32

/* Excerpt from dri2tokens.h */
/* Event sub-types for the swap complete event */
#define DRI2_EXCHANGE_COMPLETE  0x1
#define DRI2_BLIT_COMPLETE      0x2
#define DRI2_FLIP_COMPLETE      0x3


  [1] http://cgit.freedesktop.org/xorg/proto/dri2proto/tree/dri2proto.h

--
Tel: +358-44-5233421
_______________________________________________
[email protected]: X.Org support
Archives: http://lists.freedesktop.org/archives/xorg
Info: http://lists.freedesktop.org/mailman/listinfo/xorg
Your subscription address: [email protected]

Reply via email to