X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavutil%2Fframe.h;h=26261d7e40ba7e17f48ec341e37ac72c5cf830cb;hb=6655939f03eaa69ec0c1599f4bbf877d9a9d0569;hp=4d8c1bed4f8f2f22feae479feaba383d07f32710;hpb=bf0fde84d503280009e6f573ded2e43eae80901b;p=ffmpeg diff --git a/libavutil/frame.h b/libavutil/frame.h index 4d8c1bed4f8..26261d7e40b 100644 --- a/libavutil/frame.h +++ b/libavutil/frame.h @@ -25,6 +25,7 @@ #ifndef AVUTIL_FRAME_H #define AVUTIL_FRAME_H +#include #include #include "avutil.h" @@ -240,9 +241,18 @@ typedef struct AVFrame { uint8_t **extended_data; /** - * width and height of the video frame + * @name Video dimensions + * Video frames only. The coded dimensions (in pixels) of the video frame, + * i.e. the size of the rectangle that contains some well-defined values. + * + * @note The part of the frame intended for display/presentation is further + * restricted by the @ref cropping "Cropping rectangle". + * @{ */ int width, height; + /** + * @} + */ /** * number of audio samples (per channel) described by this frame @@ -530,6 +540,22 @@ typedef struct AVFrame { * purpose. */ AVBufferRef *opaque_ref; + + /** + * @anchor cropping + * @name Cropping + * Video frames only. The number of pixels to discard from the the + * top/bottom/left/right border of the frame to obtain the sub-rectangle of + * the frame intended for presentation. + * @{ + */ + size_t crop_top; + size_t crop_bottom; + size_t crop_left; + size_t crop_right; + /** + * @} + */ } AVFrame; /**