26 #define VLC_PICTURE_H 1 30 #include <stdatomic.h> 33 using std::atomic_uintptr_t;
34 using std::memory_order_relaxed;
35 using std::memory_order_release;
66 #define PICTURE_PLANE_MAX (VOUT_MAX_PLANES) 87 void (*destroy)(
void *priv);
149 bool b_top_field_first;
150 unsigned int i_nb_fields;
161 atomic_uintptr_t
refs;
222 atomic_fetch_add_explicit(&picture->
refs, (uintptr_t)1,
223 memory_order_relaxed);
236 uintptr_t
refs = atomic_fetch_sub_explicit(&picture->
refs, (uintptr_t)1,
237 memory_order_release);
303 int i_override_height,
bool b_crop );
333 #define Y_PIXELS p[Y_PLANE].p_pixels 334 #define Y_PITCH p[Y_PLANE].i_pitch 335 #define U_PIXELS p[U_PLANE].p_pixels 336 #define U_PITCH p[U_PLANE].i_pitch 337 #define V_PIXELS p[V_PLANE].p_pixels 338 #define V_PITCH p[V_PLANE].i_pitch 339 #define A_PIXELS p[A_PLANE].p_pixels 340 #define A_PITCH p[A_PLANE].i_pitch Definition: vlc_picture.h:95
private: d3d11_video_context_t*
Definition: vlc_picture.h:98
void plane_CopyPixels(plane_t *p_dst, const plane_t *p_src)
Definition: picture.c:337
int i_visible_lines
How many visible lines are there?
Definition: vlc_picture.h:59
void picture_CopyProperties(picture_t *p_dst, const picture_t *p_src)
This function will copy all picture dynamic properties.
Definition: picture.c:373
atomic_uintptr_t refs
Definition: vlc_picture.h:162
Video picture.
Definition: vlc_picture.h:126
int picture_Setup(picture_t *, const video_format_t *)
This function will setup all fields of a picture_t without allocating any memory. ...
int i_pitch
Number of bytes in a line, including margins.
Definition: vlc_picture.h:53
int picture_Export(vlc_object_t *p_obj, block_t **pp_image, video_format_t *p_fmt, picture_t *p_picture, vlc_fourcc_t i_format, int i_override_width, int i_override_height, bool b_crop)
This function will export a picture to an encoded bitstream.
Definition: picture.c:436
vlc_video_context_type
Decoder device type.
Definition: vlc_picture.h:92
Resource for a picture.
Definition: vlc_picture.h:184
int i_visible_pitch
How many visible pixels are there?
Definition: vlc_picture.h:60
Definition: vlc_picture.h:100
int i_planes
number of allocated planes
Definition: vlc_picture.h:134
picture_t * picture_NewFromFormat(const video_format_t *p_fmt)
This function will create a new picture using the given format.
#define PICTURE_PLANE_MAX
Maximum number of plane for a picture.
Definition: vlc_picture.h:67
Definition: vlc_picture.h:86
uint8_t * p_pixels
Start of the plane's data.
Definition: vlc_picture.h:49
static picture_t * picture_Hold(picture_t *picture)
Increments the picture reference count.
Definition: vlc_picture.h:221
Definition: vlc_picture.h:329
Definition: vlc_picture.h:75
Definition: vlc_picture.h:328
Definition: vlc_picture.h:102
struct picture_buffer_t picture_buffer_t
Definition: decoder_helpers.c:231
Definition: vlc_picture.h:327
Definition: vlc_picture.h:94
int64_t vlc_tick_t
High precision date or time interval.
Definition: vlc_tick.h:45
void * p_sys
Private data - the video output plugin might want to put stuff here to keep track of the picture...
Definition: vlc_picture.h:157
Definition: vlc_picture.h:99
uint32_t vlc_fourcc_t
Definition: fourcc_gen.c:33
static void picture_Release(picture_t *picture)
Decrements the picture reference count.
Definition: vlc_picture.h:235
int i_pixel_pitch
Size of a macropixel, defaults to 1.
Definition: vlc_picture.h:56
picture_t * picture_Clone(picture_t *pic)
Perform a shallow picture copy.
Definition: picture.c:408
#define vlc_assert(pred)
Run-time assertion.
Definition: vlc_common.h:267
private: d3d9_video_context_t*
Definition: vlc_picture.h:97
void picture_Copy(picture_t *p_dst, const picture_t *p_src)
This function will copy both picture dynamic properties and pixels.
Definition: picture.c:395
struct picture_t * p_next
Next picture in a FIFO a pictures.
Definition: vlc_picture.h:160
int i_lines
Number of lines, including margins.
Definition: vlc_picture.h:52
picture_t * picture_New(vlc_fourcc_t i_chroma, int i_width, int i_height, int i_sar_num, int i_sar_den)
This function will create a new picture.
Definition: picture.c:305
Decoder context struct.
Definition: vlc_codec.h:555
static void picture_SwapUV(picture_t *picture)
Swap UV planes of a Tri Planars picture.
Definition: vlc_picture.h:348
Description of a planar graphic field.
Definition: vlc_picture.h:47
void picture_CopyPixels(picture_t *p_dst, const picture_t *p_src)
This function will copy the picture pixels.
Definition: picture.c:384
struct picture_context_t picture_context_t
picture_t * picture_NewFromResource(const video_format_t *, const picture_resource_t *)
This function will create a new picture using the provided resource.
Definition: picture.c:222
#define VLC_API
Definition: fourcc_gen.c:31
vlc_video_context * vlc_video_context_Create(vlc_decoder_device *, enum vlc_video_context_type private_type, size_t private_size, const struct vlc_video_context_operations *)
Definition: decoder_helpers.c:241
void vlc_video_context_Release(vlc_video_context *)
Definition: decoder_helpers.c:277
struct plane_t plane_t
Description of a planar graphic field.
vlc_decoder_device * vlc_video_context_HoldDevice(vlc_video_context *)
Get the decoder device used by the device context.
Definition: decoder_helpers.c:289
Definition: vlc_picture.h:101
Definition: vlc_picture.h:96
vlc_video_context * vlc_video_context_Hold(vlc_video_context *)
Definition: decoder_helpers.c:271
Definition: vlc_block.h:117
void * vlc_video_context_GetPrivate(vlc_video_context *, enum vlc_video_context_type)
Definition: decoder_helpers.c:259
void picture_Destroy(picture_t *picture)
Destroys a picture without references.
Definition: picture.c:320
This file defines the elementary streams format types.
VLC object common members.
Definition: vlc_objects.h:43
enum vlc_video_context_type vlc_video_context_GetType(const vlc_video_context *)
Definition: decoder_helpers.c:266
plane_t p[(5)]
description of the planes
Definition: vlc_picture.h:133
#define VLC_USED
Definition: fourcc_gen.c:32
Definition: vlc_picture.h:330
Definition: vlc_picture.h:69
void picture_Reset(picture_t *)
This function will reset a picture information (properties and quantizers).
Definition: picture.c:88