|
xine-lib
1.2.9
|
#include <signal.h>#include <sys/time.h>#include <stdio.h>#include <stdlib.h>#include <unistd.h>#include <string.h>#include <pthread.h>#include <inttypes.h>#include <errno.h>#include <xine/xine_internal.h>#include <xine/video_out.h>#include <xine/metronom.h>#include <xine/xineutils.h>#include <yuv2rgb.h>#include "xine_private.h"Data Structures | |
| struct | vos_grab_video_frame_s |
| struct | img_buf_fifo_t |
| struct | vos_t |
Macros | |
| #define | XINE_ENABLE_EXPERIMENTAL_FEATURES |
| #define | LOG_MODULE "video_out" |
| #define | LOG_VERBOSE |
| #define | NUM_FRAME_BUFFERS 15 |
| #define | MAX_USEC_TO_SLEEP 42000 |
| #define | DEFAULT_FRAME_DURATION 3000 /* 30 frames per second */ |
| #define | FIRST_FRAME_POLL_DELAY 3000 |
| #define | FIRST_FRAME_MAX_POLL 10 /* poll n times at most */ |
| #define | EXPERIMENTAL_FRAME_QUEUE_OPTIMIZATION 1 |
| #define | timeradd(a, b, result) |
| #define | ADD_READY_FRAMES |
Typedefs | |
| typedef struct vos_grab_video_frame_s | vos_grab_video_frame_t |
| #define ADD_READY_FRAMES |
Referenced by next_frame(), paused_loop(), and video_out_loop().
| #define DEFAULT_FRAME_DURATION 3000 /* 30 frames per second */ |
Referenced by next_frame(), and vo_frame_draw().
| #define EXPERIMENTAL_FRAME_QUEUE_OPTIMIZATION 1 |
| #define FIRST_FRAME_MAX_POLL 10 /* poll n times at most */ |
Referenced by vo_frame_draw().
| #define FIRST_FRAME_POLL_DELAY 3000 |
Referenced by next_frame().
| #define LOG_MODULE "video_out" |
| #define LOG_VERBOSE |
| #define MAX_USEC_TO_SLEEP 42000 |
Referenced by video_out_loop().
| #define NUM_FRAME_BUFFERS 15 |
Referenced by _x_vo_new_port().
| #define timeradd | ( | a, | |
| b, | |||
| result | |||
| ) |
Referenced by vdpau_grab_grab_video_frame(), and vo_grab_grab_video_frame().
| #define XINE_ENABLE_EXPERIMENTAL_FEATURES |
| typedef struct vos_grab_video_frame_s vos_grab_video_frame_t |
| xine_video_port_t* _x_vo_new_port | ( | xine_t * | xine, |
| vo_driver_t * | driver, | ||
| int | grabonly | ||
| ) |
Build a video output port from a given video driver.
References _, _x_abort, _x_video_overlay_new_manager(), xine_s::clock, xine_s::config, vo_frame_s::draw, vo_frame_s::extra_info, vo_frame_s::free, vo_frame_s::id, vo_frame_s::lock, NULL, NUM_FRAME_BUFFERS, vo_frame_s::port, vo_frame_s::proc_duplicate_frame_data, config_values_s::register_num, video_out_loop(), vo_close(), vo_enable_overlay(), vo_exit(), vo_flush(), vo_frame_dec_lock(), vo_frame_draw(), vo_frame_inc_lock(), vo_get_capabilities(), vo_get_frame(), vo_get_last_frame(), vo_get_overlay_manager(), vo_get_property(), vo_new_grab_video_frame(), vo_open(), VO_PROP_MAX_NUM_FRAMES, vo_queue_append_int(), vo_queue_open(), vo_set_property(), vo_status(), vo_streams_close(), vo_streams_open(), vo_trigger_drawing(), XINE_VERBOSITY_DEBUG, XINE_VERBOSITY_LOG, XINE_VERBOSITY_NONE, and xprintf.
Referenced by xine_new_framegrab_video_port(), and xine_open_video_driver().
|
static |
Referenced by next_frame(), and paused_loop().
|
static |
References vo_frame_s::bad_frame, vo_frame_s::base, vo_frame_s::crop_bottom, vo_frame_s::crop_left, vo_frame_s::crop_right, vo_frame_s::crop_top, vo_frame_s::duration, vo_frame_s::extra_info, vo_frame_s::flags, vo_frame_s::format, vo_frame_s::height, vo_frame_s::is_first, vo_frame_s::overlay_offset_x, vo_frame_s::overlay_offset_y, vo_frame_s::pitches, vo_frame_s::proc_called, vo_frame_s::progressive_frame, vo_frame_s::pts, vo_frame_s::ratio, vo_frame_s::repeat_first_field, vo_frame_s::stream, vo_frame_s::top_field_first, VO_BOTH_FIELDS, vo_get_frame(), vo_reref(), vo_frame_s::vpts, vo_frame_s::width, XINE_IMGFMT_YUY2, XINE_IMGFMT_YV12, yuy2_to_yuy2(), and yv12_to_yv12().
Referenced by vo_frame_draw().
|
static |
References _, _x_extra_info_reset(), vo_frame_s::bad_frame, vo_frame_s::base, vo_frame_s::crop_bottom, vo_frame_s::crop_left, vo_frame_s::crop_right, vo_frame_s::crop_top, vo_frame_s::duration, vo_frame_s::extra_info, vo_frame_s::flags, vo_frame_s::format, vo_frame_s::future_frame, vo_frame_s::height, vo_frame_s::is_first, vo_frame_s::lock_counter, vo_frame_s::mutex, NULL, vo_frame_s::overlay_offset_x, vo_frame_s::overlay_offset_y, vo_frame_s::pitches, vo_frame_s::proc_called, vo_frame_s::proc_duplicate_frame_data, vo_frame_s::progressive_frame, vo_frame_s::pts, vo_frame_s::ratio, vo_frame_s::repeat_first_field, vo_frame_s::stream, vo_frame_s::top_field_first, VO_BOTH_FIELDS, vo_free_get_dupl(), vo_queue_append(), vo_ready_get_dupl(), vo_ready_refill(), vo_reref(), vo_frame_s::vpts, vo_frame_s::width, XINE_IMGFMT_YUY2, XINE_IMGFMT_YV12, XINE_VERBOSITY_LOG, xprintf, yuy2_to_yuy2(), and yv12_to_yv12().
Referenced by paused_loop(), and video_out_loop().
|
static |
References _, _x_extra_info_merge(), ADD_READY_FRAMES, check_redraw_needed(), DEFAULT_FRAME_DURATION, vo_frame_s::duration, vo_frame_s::extra_info, FIRST_FRAME_POLL_DELAY, vo_frame_s::future_frame, vo_frame_s::is_first, vo_frame_s::lock_counter, lprintf, vo_frame_s::next, NULL, vo_frame_s::pts, vo_frame_s::stream, vo_frame_dec2_lock_int(), vo_frame_dec_lock(), vo_frame_inc_lock(), vo_queue_append(), vo_queue_append_list(), vo_ready_get_all(), vo_ready_pop(), vo_frame_s::vpts, xine_log(), XINE_LOG_MSG, XINE_VERBOSITY_DEBUG, and xprintf.
Referenced by demux_mpgaudio_next(), parse_frame_payload(), video_out_loop(), vidix_config_playback(), vidix_display_frame(), write_frame_sfb(), and write_frame_YUV420P2().
|
static |
References _x_extra_info_merge(), vo_frame_s::extra_info, vo_frame_s::free, vo_frame_s::is_first, lprintf, vo_frame_s::proc_called, vo_frame_s::stream, vo_frame_driver_proc(), vo_frame_s::vpts, and extra_info_s::vpts.
Referenced by paused_loop(), and video_out_loop().
|
static |
References ADD_READY_FRAMES, check_redraw_needed(), duplicate_frame(), vo_frame_s::future_frame, NULL, overlay_and_display_frame(), vo_frame_inc_lock(), vo_grab_current_frame(), vo_list_flush(), vo_queue_read_lock(), vo_queue_read_unlock(), vo_ready_get_all(), vo_ready_pop(), vo_frame_s::vpts, XINE_SPEED_PAUSE, XINE_VERBOSITY_DEBUG, and xprintf.
Referenced by video_out_loop().
|
static |
References _, ADD_READY_FRAMES, BUF_CONTROL_FLUSH_DECODER, duplicate_frame(), vo_frame_s::id, lprintf, MAX_USEC_TO_SLEEP, next_frame(), NULL, overlay_and_display_frame(), paused_loop(), buf_element_s::type, video_out_update_disable_flush_from_video_out(), vo_frame_dec2_lock_int(), vo_frame_dec_lock(), vo_grab_current_frame(), vo_list_flush(), vo_queue_append(), vo_ready_get_all(), vo_frame_s::vpts, XINE_FINE_SPEED_NORMAL, xine_log(), XINE_LOG_MSG, XINE_SPEED_PAUSE, XINE_VERBOSITY_DEBUG, and xprintf.
Referenced by _x_vo_new_port().
|
static |
References xine_cfg_entry_s::num_value.
Referenced by video_out_loop().
|
static |
References vo_streams_unregister(), vo_unref_all(), XINE_VERBOSITY_DEBUG, and xprintf.
Referenced by _x_vo_new_port().
|
static |
References _x_freep(), yuv2rgb_s::dispose, yuv2rgb_factory_s::dispose, vos_grab_video_frame_s::grab_frame, vos_grab_video_frame_s::img, xine_grab_video_frame_s::img, vos_grab_video_frame_s::vo_frame, vo_frame_dec_lock(), vos_grab_video_frame_s::yuv2rgb, and vos_grab_video_frame_s::yuv2rgb_factory.
Referenced by vo_new_grab_video_frame().
|
static |
Referenced by _x_vo_new_port().
|
static |
References _x_free_video_driver(), _x_freep(), lprintf, vo_force_unref_all(), vo_free_img_buffers(), VO_PROP_DISCARD_FRAMES, vo_queue_close(), vo_streams_close(), XINE_VERBOSITY_DEBUG, and xprintf.
Referenced by _x_vo_new_port().
|
static |
References vo_manual_flush(), and vo_wait_flush().
Referenced by _x_vo_new_port().
|
static |
References vo_frame_s::next, NULL, vo_frame_s::stream, vo_reref(), XINE_VERBOSITY_DEBUG, and xprintf.
Referenced by vo_exit().
|
static |
References vo_frame_s::lock_counter, vo_frame_s::mutex, NULL, vo_frame_s::stream, and vo_reref().
Referenced by next_frame(), video_out_loop(), vo_list_flush(), and xine_free_video_frame().
|
static |
References vo_frame_s::lock_counter, vo_frame_s::mutex, NULL, vo_frame_s::port, vo_frame_s::stream, vo_queue_append(), and vo_reref().
Referenced by _x_vo_new_port(), next_frame(), video_out_loop(), vo_dispose_grab_video_frame(), vo_grab_current_frame(), and vo_grab_grab_video_frame().
|
static |
References _, _x_extra_info_merge(), _x_keyframes_add(), _x_stream_info_set(), vo_frame_s::bad_frame, vo_frame_s::crop_bottom, crop_frame(), vo_frame_s::crop_left, vo_frame_s::crop_right, vo_frame_s::crop_top, DEFAULT_FRAME_DURATION, xine_dropped_frames_t::discarded_frames, xine_dropped_frames_t::discarded_threshold, vo_frame_s::duration, vo_frame_s::extra_info, FIRST_FRAME_MAX_POLL, vo_frame_s::format, metronom_s::got_video_frame, vo_frame_s::height, INPUT_IS_SEEKABLE, extra_info_s::input_normpos, xine_stream_s::input_plugin, extra_info_s::input_time, vo_frame_s::is_first, vo_frame_s::lock_counter, lprintf, xine_stream_s::metronom, xine_keyframes_entry_t::msecs, xine_keyframes_entry_t::normpos, NULL, vo_frame_s::overlay_offset_x, vo_frame_s::overlay_offset_y, vo_frame_s::port, vo_frame_s::proc_called, vo_frame_s::pts, xine_dropped_frames_t::skipped_frames, xine_dropped_frames_t::skipped_threshold, vo_frame_s::stream, VO_CAP_CROP, vo_frame_driver_proc(), vo_frame_inc2_lock(), vo_queue_append(), vo_reref(), vo_frame_s::vpts, extra_info_s::vpts, vo_frame_s::width, xine_stream_s::xine, XINE_ANON_STREAM, XINE_EVENT_DROPPED_FRAMES, xine_event_send(), XINE_IMGFMT_YUY2, XINE_IMGFMT_YV12, xine_log(), XINE_LOG_MSG, XINE_STREAM_INFO_DISCARDED_FRAMES, XINE_STREAM_INFO_SKIPPED_FRAMES, XINE_VERBOSITY_DEBUG, and xprintf.
Referenced by _x_vo_new_port().
|
static |
References vo_frame_s::base, vo_frame_s::format, height, vo_frame_s::height, vo_frame_s::pitches, vo_frame_s::proc_called, vo_frame_s::proc_frame, vo_frame_s::proc_slice, XINE_IMGFMT_YUY2, and XINE_IMGFMT_YV12.
Referenced by overlay_and_display_frame(), and vo_frame_draw().
|
static |
References vo_frame_s::lock_counter, vo_frame_s::mutex, and vo_frame_s::port.
Referenced by vo_frame_draw().
|
static |
References vo_frame_s::lock_counter, vo_frame_s::mutex, and vo_frame_s::port.
Referenced by _x_vo_new_port(), next_frame(), paused_loop(), vo_get_last_frame(), vo_grab_current_frame(), and vo_grab_grab_video_frame().
|
static |
References vo_frame_s::format, vo_frame_s::height, vo_frame_s::next, NULL, vo_frame_s::ratio, and vo_frame_s::width.
Referenced by duplicate_frame().
|
static |
References _, _x_freep(), vo_queue_dispose_all(), XINE_VERBOSITY_LOG, and xprintf.
Referenced by vo_exit().
|
static |
References xine_video_port_s::get_capabilities.
Referenced by _x_vo_new_port().
|
static |
References _, _x_extra_info_reset(), vo_frame_s::bad_frame, vo_frame_s::crop_bottom, vo_frame_s::crop_left, vo_frame_s::crop_right, vo_frame_s::crop_top, vo_frame_s::extra_info, vo_frame_s::flags, vo_frame_s::format, height, vo_frame_s::height, vo_frame_s::lock_counter, lprintf, vo_frame_s::mutex, NULL, vo_frame_s::overlay_offset_x, vo_frame_s::overlay_offset_y, vo_frame_s::proc_called, vo_frame_s::progressive_frame, vo_frame_s::ratio, vo_frame_s::repeat_first_field, vo_frame_s::stream, vo_frame_s::top_field_first, vo_queue_append(), vo_queue_get_nonblock(), width, vo_frame_s::width, XINE_VERBOSITY_LOG, and xprintf.
Referenced by _x_vo_new_port(), and crop_frame().
|
static |
References vo_frame_inc_lock().
Referenced by _x_vo_new_port().
|
static |
Referenced by _x_vo_new_port().
|
static |
References VO_PROP_BUFS_FREE, VO_PROP_BUFS_IN_FIFO, VO_PROP_BUFS_TOTAL, VO_PROP_DISCARD_FRAMES, VO_PROP_NUM_STREAMS, XINE_PARAM_VO_BRIGHTNESS, XINE_PARAM_VO_CONTRAST, XINE_PARAM_VO_CROP_BOTTOM, XINE_PARAM_VO_CROP_LEFT, XINE_PARAM_VO_CROP_RIGHT, XINE_PARAM_VO_CROP_TOP, XINE_PARAM_VO_GAMMA, XINE_PARAM_VO_HUE, XINE_PARAM_VO_NOISE_REDUCTION, XINE_PARAM_VO_SATURATION, XINE_PARAM_VO_SHARPNESS, and XINE_PARAM_VO_SINGLE_STEP.
Referenced by _x_vo_new_port().
|
static |
References vos_grab_video_frame_s::finished, vo_frame_s::format, vos_grab_video_frame_s::grab_frame, vos_grab_video_frame_s::next, NULL, vo_frame_s::proc_provide_standard_frame_data, vos_grab_video_frame_s::vo_frame, vo_frame_dec_lock(), vo_frame_inc_lock(), xine_grab_video_frame_s::vpts, XINE_IMGFMT_YUY2, and XINE_IMGFMT_YV12.
Referenced by paused_loop(), and video_out_loop().
|
static |
References _x_freep(), yuv2rgb_s::configure, yuv2rgb_factory_s::create_converter, xine_grab_video_frame_s::crop_bottom, xine_grab_video_frame_s::crop_left, xine_grab_video_frame_s::crop_right, xine_grab_video_frame_s::crop_top, vos_grab_video_frame_s::finished, xine_grab_video_frame_s::flags, xine_current_frame_data_t::format, vos_grab_video_frame_s::grab_frame, vos_grab_video_frame_s::grab_height, vos_grab_video_frame_s::grab_width, height, xine_grab_video_frame_s::height, vos_grab_video_frame_s::img, xine_current_frame_data_t::img, xine_grab_video_frame_s::img, vos_grab_video_frame_s::img_size, xine_current_frame_data_t::img_size, MODE_24_RGB, vos_grab_video_frame_s::next, NULL, yuv2rgb_factory_s::set_csc_levels, xine_grab_video_frame_s::timeout, timeradd, vos_grab_video_frame_s::uv_stride, vos_grab_video_frame_s::video_port, vos_grab_video_frame_s::vo_frame, vo_frame_dec_lock(), vo_frame_inc_lock(), VO_GET_FLAGS_CM, vos_grab_video_frame_s::vo_height, vos_grab_video_frame_s::vo_width, xine_grab_video_frame_s::vpts, width, xine_grab_video_frame_s::width, XINE_GRAB_VIDEO_FRAME_FLAGS_WAIT_NEXT, XINE_IMGFMT_YUY2, XINE_IMGFMT_YV12, vos_grab_video_frame_s::y_stride, vos_grab_video_frame_s::yuv2rgb, vos_grab_video_frame_s::yuv2rgb_factory, yuv2rgb_factory_init(), yuv2rgb_s::yuv2rgb_fun, and yuv2rgb_s::yuy22rgb_fun.
Referenced by vo_new_grab_video_frame().
|
static |
References vo_frame_s::next, NULL, vo_frame_dec2_lock_int(), and vo_queue_append_list().
Referenced by paused_loop(), video_out_loop(), and vo_manual_flush().
|
static |
References NULL, and vo_list_flush().
Referenced by vo_flush(), and vo_set_property().
|
static |
References xine_grab_video_frame_s::dispose, xine_grab_video_frame_s::grab, vos_grab_video_frame_s::grab_frame, xine_grab_video_frame_s::timeout, vos_grab_video_frame_s::video_port, vo_dispose_grab_video_frame(), vo_grab_grab_video_frame(), xine_grab_video_frame_s::vpts, and XINE_GRAB_VIDEO_FRAME_DEFAULT_TIMEOUT.
Referenced by _x_vo_new_port().
|
static |
References NULL, xine_stream_s::spu_channel_user, vo_streams_register(), XINE_ANON_STREAM, XINE_VERBOSITY_DEBUG, and xprintf.
Referenced by _x_vo_new_port().
|
static |
References img_buf_fifo_t::mutex, and vo_queue_append_int().
Referenced by duplicate_frame(), next_frame(), video_out_loop(), vo_frame_dec_lock(), vo_frame_draw(), vo_get_frame(), and xine_free_video_frame().
|
static |
|
static |
|
static |
|
static |
References vo_frame_s::dispose, img_buf_fifo_t::first, img_buf_fifo_t::last, img_buf_fifo_t::mutex, vo_frame_s::next, NULL, and img_buf_fifo_t::num_buffers.
Referenced by vo_free_img_buffers().
|
static |
References img_buf_fifo_t::first, vo_frame_s::format, height, vo_frame_s::height, img_buf_fifo_t::last, img_buf_fifo_t::locked_for_read, lprintf, img_buf_fifo_t::mutex, vo_frame_s::next, img_buf_fifo_t::not_empty, NULL, img_buf_fifo_t::num_buffers, img_buf_fifo_t::num_buffers_max, vo_frame_s::ratio, width, and vo_frame_s::width.
Referenced by vo_get_frame().
|
static |
|
static |
References img_buf_fifo_t::first, img_buf_fifo_t::last, vo_frame_s::next, NULL, and img_buf_fifo_t::num_buffers.
Referenced by xine_get_next_video_frame().
|
static |
References img_buf_fifo_t::locked_for_read, and img_buf_fifo_t::mutex.
Referenced by paused_loop().
|
static |
References img_buf_fifo_t::first, img_buf_fifo_t::locked_for_read, img_buf_fifo_t::mutex, and img_buf_fifo_t::not_empty.
Referenced by paused_loop().
|
static |
References NULL.
Referenced by next_frame(), paused_loop(), and video_out_loop().
|
static |
References vo_frame_s::format, vo_frame_s::height, vo_frame_s::lock_counter, vo_frame_s::next, NULL, vo_frame_s::ratio, and vo_frame_s::width.
Referenced by duplicate_frame().
|
static |
References vo_frame_s::next, and NULL.
Referenced by next_frame(), and paused_loop().
|
static |
References NULL.
Referenced by duplicate_frame().
|
static |
References _x_refcounter_dec(), _x_refcounter_inc(), vo_frame_s::id, and vo_frame_s::stream.
Referenced by crop_frame(), duplicate_frame(), vo_force_unref_all(), vo_frame_dec2_lock_int(), vo_frame_dec_lock(), vo_frame_draw(), and vo_unref_all().
|
static |
References NULL, vo_manual_flush(), VO_PROP_DISCARD_FRAMES, vo_wait_flush(), XINE_PARAM_VO_BRIGHTNESS, XINE_PARAM_VO_CONTRAST, XINE_PARAM_VO_CROP_BOTTOM, XINE_PARAM_VO_CROP_LEFT, XINE_PARAM_VO_CROP_RIGHT, XINE_PARAM_VO_CROP_TOP, XINE_PARAM_VO_GAMMA, XINE_PARAM_VO_HUE, XINE_PARAM_VO_NOISE_REDUCTION, XINE_PARAM_VO_SATURATION, XINE_PARAM_VO_SHARPNESS, XINE_PARAM_VO_SINGLE_STEP, XINE_VERBOSITY_DEBUG, and xprintf.
Referenced by _x_vo_new_port().
|
static |
References height, width, and XINE_ANON_STREAM.
Referenced by _x_vo_new_port().
|
static |
References _x_freep().
Referenced by _x_vo_new_port(), and vo_exit().
|
static |
References NULL.
Referenced by _x_vo_new_port().
|
static |
References NULL, and XINE_ANON_STREAM.
Referenced by vo_open().
|
static |
References XINE_ANON_STREAM.
Referenced by vo_close().
|
static |
Referenced by _x_vo_new_port().
|
static |
References vo_frame_s::next, NULL, vo_frame_s::stream, vo_reref(), XINE_VERBOSITY_DEBUG, and xprintf.
Referenced by vo_close().
|
static |
Referenced by vo_flush(), and vo_set_property().
| void xine_free_video_frame | ( | xine_video_port_t * | port, |
| xine_video_frame_t * | frame | ||
| ) |
References vo_frame_s::port, vo_frame_dec2_lock_int(), and vo_queue_append().
| int xine_get_next_video_frame | ( | xine_video_port_t * | this_gen, |
| xine_video_frame_t * | frame | ||
| ) |
References vo_frame_s::base, DEMUX_OK, vo_frame_s::duration, vo_frame_s::extra_info, fifo_buffer_s::fifo_size, vo_frame_s::format, extra_info_s::frame_number, vo_frame_s::height, extra_info_s::input_normpos, extra_info_s::input_time, NULL, vo_frame_s::ratio, xine_stream_s::video_fifo, vo_queue_pop_int(), vo_frame_s::vpts, and vo_frame_s::width.
1.8.14