Give error when enabling HEVC on unsupported platforms

This commit is contained in:
Iwan Timmer
2016-03-15 18:15:42 +01:00
parent 56094f3033
commit 58da4da6c3
3 changed files with 15 additions and 0 deletions

View File

@@ -84,6 +84,11 @@ bool video_imx_init() {
}
static void decoder_renderer_setup(int videoFormat, int width, int height, int redrawRate, void* context, int drFlags) {
if (videoFormat != VIDEO_FORMAT_H264) {
fprintf(stderr, "Video format not supported\n");
exit(1);
}
struct mxcfb_gbl_alpha alpha;
dbuf.type = V4L2_BUF_TYPE_VIDEO_OUTPUT;

View File

@@ -54,6 +54,11 @@ static int port_settings_changed;
static int first_packet;
static void decoder_renderer_setup(int videoFormat, int width, int height, int redrawRate, void* context, int drFlags) {
if (videoFormat != VIDEO_FORMAT_H264) {
fprintf(stderr, "Video format not supported\n");
exit(1);
}
bcm_host_init();
gs_sps_init(width, height);

View File

@@ -33,6 +33,11 @@
static char* ffmpeg_buffer;
static void sdl_setup(int videoFormat, int width, int height, int redrawRate, void* context, int drFlags) {
if (videoFormat != VIDEO_FORMAT_H264) {
fprintf(stderr, "Video format not supported\n");
exit(1);
}
int avc_flags = SLICE_THREADING;
if (drFlags && FORCE_HARDWARE_ACCELERATION)
avc_flags |= HARDWARE_ACCELERATION;