1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

For #1685: Cross build RTC with FFmpeg

This commit is contained in:
winlin 2021-06-19 21:55:12 +08:00
parent 1c75a270b3
commit 1e9de0e191
267 changed files with 12603 additions and 1451 deletions

View file

@ -73,10 +73,8 @@ static const VDPAUPixFmtMap pix_fmts_422[] = {
};
static const VDPAUPixFmtMap pix_fmts_444[] = {
#ifdef VDP_YCBCR_FORMAT_Y_U_V_444
{ VDP_YCBCR_FORMAT_Y_U_V_444, AV_PIX_FMT_YUV444P },
#endif
{ 0, AV_PIX_FMT_NONE, },
{ VDP_YCBCR_FORMAT_YV12, AV_PIX_FMT_YUV444P },
{ 0, AV_PIX_FMT_NONE, },
};
static const struct {
@ -351,11 +349,7 @@ static int vdpau_transfer_data_from(AVHWFramesContext *ctx, AVFrame *dst,
return AVERROR(EINVAL);
}
if ((vdpau_format == VDP_YCBCR_FORMAT_YV12)
#ifdef VDP_YCBCR_FORMAT_Y_U_V_444
|| (vdpau_format == VDP_YCBCR_FORMAT_Y_U_V_444)
#endif
)
if (vdpau_format == VDP_YCBCR_FORMAT_YV12)
FFSWAP(void*, data[1], data[2]);
err = priv->get_data(surf, vdpau_format, data, linesize);
@ -406,11 +400,7 @@ static int vdpau_transfer_data_to(AVHWFramesContext *ctx, AVFrame *dst,
return AVERROR(EINVAL);
}
if ((vdpau_format == VDP_YCBCR_FORMAT_YV12)
#ifdef VDP_YCBCR_FORMAT_Y_U_V_444
|| (vdpau_format == VDP_YCBCR_FORMAT_Y_U_V_444)
#endif
)
if (vdpau_format == VDP_YCBCR_FORMAT_YV12)
FFSWAP(const void*, data[1], data[2]);
err = priv->put_data(surf, vdpau_format, data, linesize);