mirror of
https://github.com/obsproject/obs-studio.git
synced 2024-09-20 13:08:50 +02:00
deps/media-playback: Plumb linear alpha flag
This commit is contained in:
parent
1fa152092c
commit
ce6f233e2d
4
deps/media-playback/media-playback/media.c
vendored
4
deps/media-playback/media-playback/media.c
vendored
@ -419,7 +419,8 @@ static void mp_media_next_video(mp_media_t *m, bool preload)
|
||||
|
||||
frame->width = f->width;
|
||||
frame->height = f->height;
|
||||
frame->flip = flip;
|
||||
frame->flags = flip ? OBS_SOURCE_FRAME_FLIP : 0;
|
||||
frame->flags |= m->is_linear_alpha ? OBS_SOURCE_FRAME_LINEAR_ALPHA : 0;
|
||||
|
||||
if (!m->is_local_file && !d->got_first_keyframe) {
|
||||
if (!f->key_frame)
|
||||
@ -803,6 +804,7 @@ bool mp_media_init(mp_media_t *media, const struct mp_media_info *info)
|
||||
media->v_seek_cb = info->v_seek_cb;
|
||||
media->v_preload_cb = info->v_preload_cb;
|
||||
media->force_range = info->force_range;
|
||||
media->is_linear_alpha = info->is_linear_alpha;
|
||||
media->buffering = info->buffering;
|
||||
media->speed = info->speed;
|
||||
media->is_local_file = info->is_local_file;
|
||||
|
2
deps/media-playback/media-playback/media.h
vendored
2
deps/media-playback/media-playback/media.h
vendored
@ -76,6 +76,7 @@ struct mp_media {
|
||||
enum video_colorspace cur_space;
|
||||
enum video_range_type cur_range;
|
||||
enum video_range_type force_range;
|
||||
bool is_linear_alpha;
|
||||
|
||||
int64_t play_sys_ts;
|
||||
int64_t next_pts_ns;
|
||||
@ -119,6 +120,7 @@ struct mp_media_info {
|
||||
int buffering;
|
||||
int speed;
|
||||
enum video_range_type force_range;
|
||||
bool is_linear_alpha;
|
||||
bool hardware_decoding;
|
||||
bool is_local_file;
|
||||
bool reconnecting;
|
||||
|
Loading…
Reference in New Issue
Block a user