xine-lib 1.2.13-20230125hg15249
|
#include "config.h"
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <inttypes.h>
#include <xine/xine_internal.h>
#include <xine/video_out.h>
#include "mpeg2_internal.h"
#include <xine/xineutils.h>
#include <xine/attributes.h>
#include "accel_xvmc.h"
#include "xvmc.h"
#include "vlc.h"
Macros | |
#define | MOTION_ACCEL XINE_VO_MOTION_ACCEL |
#define | IDCT_ACCEL XINE_VO_IDCT_ACCEL |
#define | SIGNED_INTRA XINE_VO_SIGNED_INTRA |
#define | ACCEL (MOTION_ACCEL | IDCT_ACCEL) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | SATURATE(val) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | MOTION_CALL(routine, direction) |
#define | NEXT_MACROBLOCK |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
#define | bit_buf (picture->bitstream_buf) |
#define | bits (picture->bitstream_bits) |
#define | bit_ptr (picture->bitstream_ptr) |
Functions | |
void | xvmc_setup_scan_ptable (void) |
static int | get_xvmc_macroblock_modes (picture_t *picture) |
static int | get_xvmc_quantizer_scale (picture_t *picture) |
static int | get_xvmc_motion_delta (picture_t *picture, int f_code) |
static int | bound_motion_vector (int vec, int f_code) |
static int | get_xvmc_dmv (picture_t *picture) |
static int | get_xvmc_coded_block_pattern (picture_t *picture) |
static int | get_xvmc_luma_dc_dct_diff (picture_t *picture) |
static int | get_xvmc_chroma_dc_dct_diff (picture_t *picture) |
static void | get_xvmc_intra_block_B14 (picture_t *picture) |
static void | get_xvmc_intra_block_B15 (picture_t *picture) |
static void | get_xvmc_non_intra_block (picture_t *picture) |
static void | get_xvmc_mpeg1_intra_block (picture_t *picture) |
static void | get_xvmc_mpeg1_non_intra_block (picture_t *picture) |
static void | slice_xvmc_intra_DCT (picture_t *picture, int cc, uint8_t *dest, int stride) |
static void | slice_xvmc_non_intra_DCT (picture_t *picture, uint8_t *dest, int stride) |
static void | motion_mp1 (picture_t *picture, motion_t *motion, void(**table)(uint8_t *, uint8_t *, int, int)) |
static void | motion_fr_frame (picture_t *picture, motion_t *motion, void(**table)(uint8_t *, uint8_t *, int, int)) |
static void | motion_fr_field (picture_t *picture, motion_t *motion, void(**table)(uint8_t *, uint8_t *, int, int), int dir) |
static void | motion_fr_dmv (picture_t *picture, motion_t *motion, void(**table)(uint8_t *, uint8_t *, int, int)) |
static void | motion_fr_conceal (picture_t *picture) |
static void | motion_fi_field (picture_t *picture, motion_t *motion, void(**table)(uint8_t *, uint8_t *, int, int)) |
static void | motion_fi_16x8 (picture_t *picture, motion_t *motion, void(**table)(uint8_t *, uint8_t *, int, int)) |
static void | motion_fi_dmv (picture_t *picture, motion_t *motion, void(**table)(uint8_t *, uint8_t *, int, int)) |
static void | motion_fi_conceal (picture_t *picture) |
static int | slice_xvmc_init (picture_t *picture, int code) |
void | mpeg2_xvmc_slice (mpeg2dec_accel_t *accel, picture_t *picture, int code, uint8_t *buffer) |
Variables | |
static const uint8_t | mpeg2_scan_norm_orig [64] |
static const uint8_t | mpeg2_scan_alt_orig [64] |
static uint8_t | mpeg2_scan_alt_ptable [64] |
static uint8_t | mpeg2_scan_norm_ptable [64] |
static uint8_t | mpeg2_scan_orig_ptable [64] |
static const int | non_linear_quantizer_scale [] |
#define ACCEL (MOTION_ACCEL | IDCT_ACCEL) |
Referenced by mpeg2_xvmc_slice(), slice_xvmc_init(), slice_xvmc_intra_DCT(), and slice_xvmc_non_intra_DCT().
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_buf (picture->bitstream_buf) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bit_ptr (picture->bitstream_ptr) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define bits (picture->bitstream_bits) |
#define IDCT_ACCEL XINE_VO_IDCT_ACCEL |
#define MOTION_ACCEL XINE_VO_MOTION_ACCEL |
Referenced by mpeg2_xvmc_slice(), slice_xvmc_init(), slice_xvmc_intra_DCT(), and slice_xvmc_non_intra_DCT().
#define MOTION_CALL | ( | routine, | |
direction ) |
Referenced by mpeg2_xvmc_slice().
#define NEXT_MACROBLOCK |
Referenced by mpeg2_xvmc_slice().
#define SATURATE | ( | val | ) |
Referenced by get_xvmc_intra_block_B14(), get_xvmc_intra_block_B15(), get_xvmc_mpeg1_intra_block(), get_xvmc_mpeg1_non_intra_block(), and get_xvmc_non_intra_block().
#define SIGNED_INTRA XINE_VO_SIGNED_INTRA |
Referenced by mpeg2_xvmc_slice(), and slice_xvmc_init().
|
inlinestatic |
|
inlinestatic |
References bit_buf, bit_ptr, bits, DC_chrom_5, DC_long, DUMPBITS, DCtab::len, NEEDBITS, SBITS, DCtab::size, and UBITS.
Referenced by slice_xvmc_intra_DCT().
|
inlinestatic |
References bit_buf, bit_ptr, bits, CBPtab::cbp, CBP_7, CBP_9, DUMPBITS, CBPtab::len, NEEDBITS, and UBITS.
Referenced by mpeg2_xvmc_slice().
|
inlinestatic |
References bit_buf, bits, DMVtab::dmv, DMV_2, DUMPBITS, DMVtab::len, and UBITS.
|
static |
References bit_buf, bit_ptr, bits, DCT_13, DCT_15, DCT_16, DCT_B14_10, DCT_B14_8, DCT_B14AC_5, DUMPBITS, GETWORD, IDCT_ACCEL, DCTtab::len, DCTtab::level, mpeg2_scan_alt_orig, mpeg2_scan_alt_ptable, mpeg2_scan_norm, mpeg2_scan_norm_orig, mpeg2_scan_norm_ptable, mpeg2_scan_orig_ptable, NEEDBITS, DCTtab::run, SATURATE, SBITS, and UBITS.
Referenced by slice_xvmc_intra_DCT().
|
static |
References bit_buf, bit_ptr, bits, DCT_13, DCT_15, DCT_16, DCT_B15_10, DCT_B15_8, DUMPBITS, GETWORD, IDCT_ACCEL, DCTtab::len, DCTtab::level, mpeg2_scan_alt_orig, mpeg2_scan_alt_ptable, mpeg2_scan_norm, mpeg2_scan_norm_orig, mpeg2_scan_norm_ptable, mpeg2_scan_orig_ptable, NEEDBITS, DCTtab::run, SATURATE, SBITS, and UBITS.
Referenced by slice_xvmc_intra_DCT().
|
inlinestatic |
References bit_buf, bit_ptr, bits, DC_long, DC_lum_5, DUMPBITS, DCtab::len, NEEDBITS, SBITS, DCtab::size, and UBITS.
Referenced by slice_xvmc_intra_DCT().
|
inlinestatic |
References B_TYPE, bit_buf, bits, D_TYPE, DCT_TYPE_INTERLACED, DUMPBITS, FRAME_PICTURE, I_TYPE, MBtab::len, MACROBLOCK_INTRA, MACROBLOCK_MOTION_FORWARD, MACROBLOCK_PATTERN, MB_B, MB_I, MB_P, MC_FRAME, MBtab::modes, MOTION_TYPE_BASE, P_TYPE, and UBITS.
Referenced by mpeg2_xvmc_slice().
|
inlinestatic |
References bit_buf, bit_ptr, bits, MVtab::delta, DUMPBITS, MVtab::len, MV_10, MV_4, NEEDBITS, SBITS, and UBITS.
Referenced by motion_fi_16x8(), motion_fi_conceal(), motion_fi_dmv(), motion_fi_field(), motion_fr_conceal(), motion_fr_dmv(), motion_fr_field(), motion_fr_frame(), and motion_mp1().
|
static |
References bit_buf, bit_ptr, bits, DCT_13, DCT_15, DCT_16, DCT_B14_10, DCT_B14_8, DCT_B14AC_5, DUMPBITS, GETWORD, IDCT_ACCEL, DCTtab::len, DCTtab::level, mpeg2_scan_alt_orig, mpeg2_scan_alt_ptable, mpeg2_scan_norm, mpeg2_scan_norm_orig, mpeg2_scan_norm_ptable, mpeg2_scan_orig_ptable, NEEDBITS, DCTtab::run, SATURATE, SBITS, and UBITS.
Referenced by slice_xvmc_intra_DCT().
|
static |
References bit_buf, bit_ptr, bits, DCT_13, DCT_15, DCT_16, DCT_B14_10, DCT_B14_8, DCT_B14AC_5, DCT_B14DC_5, DUMPBITS, GETWORD, IDCT_ACCEL, DCTtab::len, DCTtab::level, mpeg2_scan_alt_orig, mpeg2_scan_alt_ptable, mpeg2_scan_norm, mpeg2_scan_norm_orig, mpeg2_scan_norm_ptable, mpeg2_scan_orig_ptable, NEEDBITS, DCTtab::run, SATURATE, SBITS, and UBITS.
Referenced by slice_xvmc_non_intra_DCT().
|
static |
References bit_buf, bit_ptr, bits, DCT_13, DCT_15, DCT_16, DCT_B14_10, DCT_B14_8, DCT_B14AC_5, DCT_B14DC_5, DUMPBITS, GETWORD, IDCT_ACCEL, DCTtab::len, DCTtab::level, mpeg2_scan_alt_orig, mpeg2_scan_alt_ptable, mpeg2_scan_norm, mpeg2_scan_norm_orig, mpeg2_scan_norm_ptable, mpeg2_scan_orig_ptable, NEEDBITS, DCTtab::run, SATURATE, SBITS, and UBITS.
Referenced by slice_xvmc_non_intra_DCT().
|
inlinestatic |
References bit_buf, bits, DUMPBITS, non_linear_quantizer_scale, and UBITS.
Referenced by mpeg2_xvmc_slice(), and slice_xvmc_init().
|
static |
References bit_buf, bit_ptr, bits, bound_motion_vector(), DUMPBITS, motion_t::f_code, get_xvmc_motion_delta(), NEEDBITS, and motion_t::pmv.
Referenced by mpeg2_xvmc_slice().
|
static |
References bit_buf, bit_ptr, bits, bound_motion_vector(), DUMPBITS, get_xvmc_motion_delta(), and NEEDBITS.
Referenced by mpeg2_xvmc_slice().
|
static |
References bit_buf, bit_ptr, bits, bound_motion_vector(), motion_t::f_code, get_xvmc_motion_delta(), NEEDBITS, and motion_t::pmv.
Referenced by mpeg2_xvmc_slice().
|
static |
References bit_buf, bit_ptr, bits, bound_motion_vector(), DUMPBITS, motion_t::f_code, get_xvmc_motion_delta(), NEEDBITS, and motion_t::pmv.
Referenced by mpeg2_xvmc_slice().
|
static |
References bit_buf, bit_ptr, bits, bound_motion_vector(), DUMPBITS, get_xvmc_motion_delta(), and NEEDBITS.
Referenced by mpeg2_xvmc_slice().
|
static |
References bit_buf, bit_ptr, bits, bound_motion_vector(), motion_t::f_code, get_xvmc_motion_delta(), NEEDBITS, and motion_t::pmv.
Referenced by mpeg2_xvmc_slice().
|
static |
References bit_buf, bit_ptr, bits, bound_motion_vector(), DUMPBITS, motion_t::f_code, field, get_xvmc_motion_delta(), NEEDBITS, motion_t::pmv, and UBITS.
Referenced by mpeg2_xvmc_slice().
|
static |
References bit_buf, bit_ptr, bits, bound_motion_vector(), motion_t::f_code, get_xvmc_motion_delta(), NEEDBITS, and motion_t::pmv.
Referenced by mpeg2_xvmc_slice().
|
static |
References bit_buf, bit_ptr, bits, bound_motion_vector(), motion_t::f_code, get_xvmc_motion_delta(), NEEDBITS, and motion_t::pmv.
Referenced by mpeg2_xvmc_slice().
void mpeg2_xvmc_slice | ( | mpeg2dec_accel_t * | accel, |
picture_t * | picture, | ||
int | code, | ||
uint8_t * | buffer ) |
References ACCEL, mpeg2_mc_t::avg, bit_buf, bit_ptr, bits, bitstream_init(), BOTTOM_FIELD, code, D_TYPE, DCT_TYPE_INTERLACED, DUMPBITS, FRAME_PICTURE, get_xvmc_coded_block_pattern(), get_xvmc_macroblock_modes(), get_xvmc_quantizer_scale(), MBAtab::len, MACROBLOCK_INTRA, MACROBLOCK_MOTION_BACKWARD, MACROBLOCK_MOTION_FORWARD, MACROBLOCK_PATTERN, MACROBLOCK_QUANT, MBAtab::mba, MBA_11, MBA_5, MC_16X8, MC_DMV, MC_FIELD, MC_FRAME, MOTION_ACCEL, MOTION_CALL, motion_fi_16x8(), motion_fi_conceal(), motion_fi_dmv(), motion_fi_field(), motion_fr_conceal(), motion_fr_dmv(), motion_fr_field(), motion_fr_frame(), motion_mp1(), MOTION_TYPE_MASK, mpeg2_cpu_state_restore, mpeg2_cpu_state_save, mpeg2_mc, NEEDBITS, NEXT_MACROBLOCK, P_TYPE, xine_xvmc_s::proc_macro_block, mpeg2_mc_t::put, SIGNED_INTRA, slice_xvmc_init(), slice_xvmc_intra_DCT(), slice_xvmc_non_intra_DCT(), UBITS, XINE_MC_FIELD, XINE_MC_FRAME, and mpeg2dec_accel_t::xvmc_last_slice_code.
Referenced by libmpeg2_accel_slice().
|
inlinestatic |
References ACCEL, B_TYPE, vo_frame_s::base, bit_buf, bit_ptr, bits, BOTTOM_FIELD, code, DUMPBITS, FRAME_PICTURE, get_xvmc_quantizer_scale(), height, MBAtab::len, MBAtab::mba, MBA_11, MBA_5, MOTION_ACCEL, NEEDBITS, NULL, SIGNED_INTRA, TOP_FIELD, and UBITS.
Referenced by mpeg2_xvmc_slice().
|
inlinestatic |
References ACCEL, bit_buf, bit_ptr, bits, D_TYPE, get_xvmc_chroma_dc_dct_diff(), get_xvmc_intra_block_B14(), get_xvmc_intra_block_B15(), get_xvmc_luma_dc_dct_diff(), get_xvmc_mpeg1_intra_block(), MOTION_ACCEL, mpeg2_idct, mpeg2_zero_block, and NEEDBITS.
Referenced by mpeg2_xvmc_slice().
|
inlinestatic |
References ACCEL, get_xvmc_mpeg1_non_intra_block(), get_xvmc_non_intra_block(), MOTION_ACCEL, mpeg2_idct, and mpeg2_zero_block.
Referenced by mpeg2_xvmc_slice().
void xvmc_setup_scan_ptable | ( | void | ) |
References mpeg2_scan_alt, mpeg2_scan_alt_orig, mpeg2_scan_alt_ptable, mpeg2_scan_norm, mpeg2_scan_norm_orig, mpeg2_scan_norm_ptable, and mpeg2_scan_orig_ptable.
Referenced by libmpeg2_accel_scan().
|
static |
Referenced by get_xvmc_intra_block_B14(), get_xvmc_intra_block_B15(), get_xvmc_mpeg1_intra_block(), get_xvmc_mpeg1_non_intra_block(), get_xvmc_non_intra_block(), and xvmc_setup_scan_ptable().
|
static |
|
static |
Referenced by get_xvmc_intra_block_B14(), get_xvmc_intra_block_B15(), get_xvmc_mpeg1_intra_block(), get_xvmc_mpeg1_non_intra_block(), get_xvmc_non_intra_block(), and xvmc_setup_scan_ptable().
|
static |
|
static |
|
static |
Referenced by get_xvmc_quantizer_scale().