develop/utils/rocvideodecode/roc_video_dec.h File Reference#
roc_video_dec.h File Reference
The AMD Video Decode Library. More...
#include <assert.h>
#include <stdint.h>
#include <mutex>
#include <vector>
#include <string>
#include <iostream>
#include <sstream>
#include <string.h>
#include <queue>
#include <stdexcept>
#include <exception>
#include <cstring>
#include <unordered_map>
#include <chrono>
#include <hip/hip_runtime.h>
#include "libavutil/md5.h"
#include "libavutil/mem.h"
#include "rocdecode.h"
#include "rocparser.h"
Go to the source code of this file.
Data Structures | |
class | RocVideoDecodeException |
struct | Rect |
struct | Dim |
struct | DecFrameBuffer_ |
struct | OutputSurfaceInfoType |
struct | ReconfigParams_t |
class | RocVideoDecoder |
Macros | |
#define | MAX_FRAME_NUM 16 |
#define | TOSTR(X) std::to_string(static_cast<int>(X)) |
#define | STR(X) std::string(X) |
#define | INFO(X) ; |
#define | ERR(X) std::cerr << "[ERR] " << " {" << __func__ <<"} " << " " << X << std::endl; |
#define | ROCDEC_THROW(X, CODE) throw RocVideoDecodeException(" { " + std::string(__func__) + " } " + X , CODE); |
#define | THROW(X) throw RocVideoDecodeException(" { " + std::string(__func__) + " } " + X); |
#define | ROCDEC_API_CALL(rocDecAPI) |
#define | HIP_API_CALL(call) |
Typedefs | |
typedef int(ROCDECAPI * | PFNRECONFIGUEFLUSHCALLBACK) (void *, uint32_t, void *) |
typedef enum SeiAvcHevcPayloadType_enum | SeiAvcHevcPayloadType |
typedef enum OutputSurfaceMemoryType_enum | OutputSurfaceMemoryType |
typedef struct DecFrameBuffer_ | DecFrameBuffer |
typedef struct OutputSurfaceInfoType | OutputSurfaceInfo |
typedef struct ReconfigParams_t | ReconfigParams |
Enumerations | |
enum | SeiAvcHevcPayloadType_enum { SEI_TYPE_TIME_CODE = 136 , SEI_TYPE_USER_DATA_UNREGISTERED = 5 } |
enum | OutputSurfaceMemoryType_enum { OUT_SURFACE_MEM_DEV_INTERNAL = 0 , OUT_SURFACE_MEM_DEV_COPIED = 1 , OUT_SURFACE_MEM_HOST_COPIED = 2 , OUT_SURFACE_MEM_NOT_MAPPED = 3 } |
Detailed Description
The AMD Video Decode Library.
Macro Definition Documentation
◆ HIP_API_CALL
#define HIP_API_CALL | ( | call | ) |
Value:
do { \
hipError_t hip_status = call; \
if (hip_status != hipSuccess) { \
const char *sz_err_name = NULL; \
sz_err_name = hipGetErrorName(hip_status); \
std::ostringstream error_log; \
error_log << "hip API error " << sz_err_name ; \
ROCDEC_THROW(error_log.str(), hip_status); \
} \
} \
while (0)
◆ ROCDEC_API_CALL
#define ROCDEC_API_CALL | ( | rocDecAPI | ) |
Value:
do { \
rocDecStatus error_code = rocDecAPI; \
if( error_code != ROCDEC_SUCCESS) { \
std::ostringstream error_log; \
error_log << #rocDecAPI << " returned " << rocDecGetErrorName(error_code) << " at " <<__FILE__ <<":" << __LINE__;\
ROCDEC_THROW(error_log.str(), error_code); \
} \
} while (0)
const char *ROCDECAPI rocDecGetErrorName(rocDecStatus rocdec_status)