Path: blob/a-new-beginning/libavcodec.xcframework/macos-arm64/libavcodec.framework/Versions/A/Headers/xvmc.h
2 views
/*1* Copyright (C) 2003 Ivan Kalvachev2*3* This file is part of FFmpeg.4*5* FFmpeg is free software; you can redistribute it and/or6* modify it under the terms of the GNU Lesser General Public7* License as published by the Free Software Foundation; either8* version 2.1 of the License, or (at your option) any later version.9*10* FFmpeg is distributed in the hope that it will be useful,11* but WITHOUT ANY WARRANTY; without even the implied warranty of12* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU13* Lesser General Public License for more details.14*15* You should have received a copy of the GNU Lesser General Public16* License along with FFmpeg; if not, write to the Free Software17* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA18*/1920#ifndef AVCODEC_XVMC_H21#define AVCODEC_XVMC_H2223/**24* @file25* @ingroup lavc_codec_hwaccel_xvmc26* Public libavcodec XvMC header.27*/2829#pragma message("XvMC is no longer supported; this header is deprecated and will be removed")3031#include <X11/extensions/XvMC.h>3233#include "libavutil/attributes.h"34#include "avcodec.h"3536/**37* @defgroup lavc_codec_hwaccel_xvmc XvMC38* @ingroup lavc_codec_hwaccel39*40* @{41*/4243#define AV_XVMC_ID 0x1DC711C0 /**< special value to ensure that regular pixel routines haven't corrupted the struct44the number is 1337 speak for the letters IDCT MCo (motion compensation) */4546struct attribute_deprecated xvmc_pix_fmt {47/** The field contains the special constant value AV_XVMC_ID.48It is used as a test that the application correctly uses the API,49and that there is no corruption caused by pixel routines.50- application - set during initialization51- libavcodec - unchanged52*/53int xvmc_id;5455/** Pointer to the block array allocated by XvMCCreateBlocks().56The array has to be freed by XvMCDestroyBlocks().57Each group of 64 values represents one data block of differential58pixel information (in MoCo mode) or coefficients for IDCT.59- application - set the pointer during initialization60- libavcodec - fills coefficients/pixel data into the array61*/62short* data_blocks;6364/** Pointer to the macroblock description array allocated by65XvMCCreateMacroBlocks() and freed by XvMCDestroyMacroBlocks().66- application - set the pointer during initialization67- libavcodec - fills description data into the array68*/69XvMCMacroBlock* mv_blocks;7071/** Number of macroblock descriptions that can be stored in the mv_blocks72array.73- application - set during initialization74- libavcodec - unchanged75*/76int allocated_mv_blocks;7778/** Number of blocks that can be stored at once in the data_blocks array.79- application - set during initialization80- libavcodec - unchanged81*/82int allocated_data_blocks;8384/** Indicate that the hardware would interpret data_blocks as IDCT85coefficients and perform IDCT on them.86- application - set during initialization87- libavcodec - unchanged88*/89int idct;9091/** In MoCo mode it indicates that intra macroblocks are assumed to be in92unsigned format; same as the XVMC_INTRA_UNSIGNED flag.93- application - set during initialization94- libavcodec - unchanged95*/96int unsigned_intra;9798/** Pointer to the surface allocated by XvMCCreateSurface().99It has to be freed by XvMCDestroySurface() on application exit.100It identifies the frame and its state on the video hardware.101- application - set during initialization102- libavcodec - unchanged103*/104XvMCSurface* p_surface;105106/** Set by the decoder before calling ff_draw_horiz_band(),107needed by the XvMCRenderSurface function. */108//@{109/** Pointer to the surface used as past reference110- application - unchanged111- libavcodec - set112*/113XvMCSurface* p_past_surface;114115/** Pointer to the surface used as future reference116- application - unchanged117- libavcodec - set118*/119XvMCSurface* p_future_surface;120121/** top/bottom field or frame122- application - unchanged123- libavcodec - set124*/125unsigned int picture_structure;126127/** XVMC_SECOND_FIELD - 1st or 2nd field in the sequence128- application - unchanged129- libavcodec - set130*/131unsigned int flags;132//}@133134/** Number of macroblock descriptions in the mv_blocks array135that have already been passed to the hardware.136- application - zeroes it on get_buffer().137A successful ff_draw_horiz_band() may increment it138with filled_mb_block_num or zero both.139- libavcodec - unchanged140*/141int start_mv_blocks_num;142143/** Number of new macroblock descriptions in the mv_blocks array (after144start_mv_blocks_num) that are filled by libavcodec and have to be145passed to the hardware.146- application - zeroes it on get_buffer() or after successful147ff_draw_horiz_band().148- libavcodec - increment with one of each stored MB149*/150int filled_mv_blocks_num;151152/** Number of the next free data block; one data block consists of15364 short values in the data_blocks array.154All blocks before this one have already been claimed by placing their155position into the corresponding block description structure field,156that are part of the mv_blocks array.157- application - zeroes it on get_buffer().158A successful ff_draw_horiz_band() may zero it together159with start_mb_blocks_num.160- libavcodec - each decoded macroblock increases it by the number161of coded blocks it contains.162*/163int next_free_data_block_num;164};165166/**167* @}168*/169170#endif /* AVCODEC_XVMC_H */171172173