On Thu, 25 Oct 2001, Sottek, Matthew J wrote: > Ok, I slightly modified the idea to take care of this too. I must > say, I really really like this one. > > #define XV_TOP_FIELD 0x01 > #define XV_BOTTOM_FIELD 0x02 > #define XV_FRAME (XV_TOP_FIELD | XV_BOTTOM_FIELD) > #define XV_HOLD 0x04 > > Mostly the same behavior as before, but now we really use these as > bitfields. When the XV_HOLD bit is ON, the data is not updated > onscreen at the end of an XvShmPutImage. It has to wait until the > HOLD bit is removed. > Here is the change, Bits 0 and 1 indicate the fields that will be > updated with the next XvShmPutImage. The image position and scaling > information are always updated. Here are some example uses. > > Default Case: (Works just like it does now) > XV_FRAME_TYPE = XV_TOP_FIELD | XV_BOTTOM_FIELD (Default) > XvShmPutImage: Both fields are updated from the XvImage, the data > is updated asap onscreen since the HOLD bit is not on. > > Interlaced Video: > XV_FRAME_TYPE = XV_HOLD | XV_TOP_FIELD | XV_BOTTOM_FIELD > XvShmPutImage: The top field and bottom field are updated from the > XvImage. The position, size and scaling information are updated > from the call, but the overlay is not updated onscreen.
XV_TOP_FIELD | XV_BOTTOM_FIELD is redundant. You can't not copy both fields. > XV_FRAME_TYPE = XV_TOP_FIELD > The overlay is updated with the latest information and set to > show only the top field. The onscreen update happens asap. > XV_FRAME_TYPE = XV_BOTTOM_FIELD > The overlay is set to show the bottom field and the onscreen update > happens asap. > > Paused Video: > Loop: > XV_FRAME_TYPE = XV_HOLD > XvShmPutImage: NO Fields are updated from the XvImage, but the > position and scaling information are taken from the call. The > overlay is not updated onscreen. > XV_FRAME_TYPE = XV_TOP_FIELD > On Screen changed happen asap. > goto Loop This is confusing. I don't understand what you are trying to do here. Mark. > > Paused Video (Better way): > Loop: > XV_FRAME_TYPE = 0x0 > XvShmPutImage: NO Fields are updated from the XvImage, the position > and scaling information are updated. The HOLD bit is not set so > overlay is updated asap. This means that for a pause you just set > The frame type to 0 and continue with puts as normal. No data > copying takes place. > goto Loop > > > Field at a Time Interlaced: > XV_FRAME_TYPE = XV_HOLD | XV_TOP_FIELD > XvShmPutImage: Only the top field is read from the XvImage. This is > done by taking the first line and then skipping every other line. > The position, size and scaling are updated from the call. > XV_FRAME_TYPE = XV_TOP_FIELD > Update on screen happens asap. > XV_FRAME_TYPE = XV_HOLD | XV_BOTTOM_FIELD > XvShmPutImage: Only the bottom field is read from the XvImage. > Position, size and scaling are updated but not onscreen. > XV_FRAME_TYPE = XV_BOTTOM_FIELD > Onscreen update happens asap. > Repeat. > > > -Matt > _______________________________________________ Xpert mailing list [EMAIL PROTECTED] http://XFree86.Org/mailman/listinfo/xpert