diff options
author | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2009-02-14 08:22:49 +0000 |
---|---|---|
committer | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2009-02-14 08:22:49 +0000 |
commit | f78c49e030f3cfbf12e8ae73fcae6d804dfd7e04 (patch) | |
tree | 30b6b9c4bbb2fd0f6144d5130d141a9f34e4cc91 /libmpcodecs/mp_image.h | |
parent | 9f8792e639fee0b706dc5ec83e9b9fa0cf432e61 (diff) | |
download | mpv-f78c49e030f3cfbf12e8ae73fcae6d804dfd7e04.tar.bz2 mpv-f78c49e030f3cfbf12e8ae73fcae6d804dfd7e04.tar.xz |
Add MP_IMGTYPE_NUMBERED which gives access to the kind of mp_image_t that
are numbered and have a "in use" flag which is necessary for proper
buffer management as e.g. H.264 direct-rendering needs and is already used
successfully for the -vo vdpau work-in-progress.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28550 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpcodecs/mp_image.h')
-rw-r--r-- | libmpcodecs/mp_image.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/libmpcodecs/mp_image.h b/libmpcodecs/mp_image.h index 512f83e8c5..ad92421787 100644 --- a/libmpcodecs/mp_image.h +++ b/libmpcodecs/mp_image.h @@ -53,6 +53,8 @@ // buffer type was printed (do NOT set this flag - it's for INTERNAL USE!!!) #define MP_IMGFLAG_TYPE_DISPLAYED 0x8000 +// set if it can not be reused yet (for MP_IMGTYPE_NUMBERED) +#define MP_IMGFLAG_IN_USE 0x10000 // codec doesn't support any form of direct rendering - it has own buffer // allocation. so we just export its buffer pointers: @@ -65,6 +67,8 @@ #define MP_IMGTYPE_IP 3 // I+P+B type, requires 2+ independent static R/W and 1+ temp WO buffers #define MP_IMGTYPE_IPB 4 +// Upper 16 bits give desired buffer number, -1 means get next available +#define MP_IMGTYPE_NUMBERED 5 #define MP_MAX_PLANES 4 @@ -76,8 +80,9 @@ #define MP_IMGFIELD_INTERLACED 0x20 typedef struct mp_image_s { - unsigned short flags; + unsigned int flags; unsigned char type; + int number; unsigned char bpp; // bits/pixel. NOT depth! for RGB it will be n*8 unsigned int imgfmt; int width,height; // stored dimensions |