]> git.pld-linux.org Git - packages/gpac.git/blob - ffmpeg3.patch
- fix building with ffmepg 4.0
[packages/gpac.git] / ffmpeg3.patch
1 --- gpac/applications/dashcast/video_encoder.c~ 2014-10-07 23:10:04.000000000 +0200
2 +++ gpac/applications/dashcast/video_encoder.c  2016-03-23 08:34:30.284438268 +0100
3 @@ -87,7 +87,7 @@
4                 video_output_file->codec_ctx->time_base.den = video_data_conf->time_base.den;
5                 video_output_file->codec_ctx->time_base.num = video_data_conf->time_base.num * video_data_conf->time_base.den / video_data_conf->framerate;
6         }
7 -       video_output_file->codec_ctx->pix_fmt = PIX_FMT_YUV420P;
8 +       video_output_file->codec_ctx->pix_fmt = AV_PIX_FMT_YUV420P;
9         video_output_file->codec_ctx->gop_size = video_data_conf->framerate;
10  
11  //     video_output_file->codec_ctx->codec_id = video_codec->id;
12 --- gpac/applications/dashcast/video_muxer.c~   2014-10-07 23:10:04.000000000 +0200
13 +++ gpac/applications/dashcast/video_muxer.c    2016-03-23 08:35:04.941564779 +0100
14 @@ -642,7 +642,7 @@
15  
16         video_stream->codec->time_base = video_codec_ctx->time_base;
17  
18 -       video_stream->codec->pix_fmt = PIX_FMT_YUV420P;
19 +       video_stream->codec->pix_fmt = AV_PIX_FMT_YUV420P;
20         video_stream->codec->gop_size = video_codec_ctx->time_base.den; //video_output_file->video_data_conf->framerate;
21  
22         av_opt_set(video_stream->codec->priv_data, "preset", "ultrafast", 0);
23 --- gpac/applications/dashcast/video_scaler.c~  2014-10-07 23:10:04.000000000 +0200
24 +++ gpac/applications/dashcast/video_scaler.c   2016-03-23 08:35:29.971877188 +0100
25 @@ -125,7 +125,7 @@
26         dc_consumer_init(&video_scaled_data->consumer, video_cb_size, name);
27  
28         video_scaled_data->num_producers = max_source;
29 -       video_scaled_data->out_pix_fmt = PIX_FMT_YUV420P;
30 +       video_scaled_data->out_pix_fmt = AV_PIX_FMT_YUV420P;
31         GF_SAFE_ALLOC_N(video_scaled_data->vsprop, max_source, VideoScaledProp);
32         memset(video_scaled_data->vsprop, 0, max_source * sizeof(VideoScaledProp));
33  
34 @@ -189,7 +189,7 @@
35                 video_scaled_data_node->cropped_frame->width  = video_input_data->vprop[index].width  - video_input_data->vprop[index].crop_x;
36                 video_scaled_data_node->cropped_frame->height = video_input_data->vprop[index].height - video_input_data->vprop[index].crop_y;
37  #endif
38 -               if (av_picture_crop((AVPicture*)video_scaled_data_node->cropped_frame, (AVPicture*)video_data_node->vframe, PIX_FMT_YUV420P, video_input_data->vprop[index].crop_y, video_input_data->vprop[index].crop_x) < 0) {
39 +               if (av_picture_crop((AVPicture*)video_scaled_data_node->cropped_frame, (AVPicture*)video_data_node->vframe, AV_PIX_FMT_YUV420P, video_input_data->vprop[index].crop_y, video_input_data->vprop[index].crop_x) < 0) {
40                         GF_LOG(GF_LOG_ERROR, GF_LOG_DASH, ("Video scaler: error while cropping picture.\n"));
41                         return -1;
42                 }
43 --- gpac/applications/dashcast/audio_decoder.c~ 2014-10-07 23:10:04.000000000 +0200
44 +++ gpac/applications/dashcast/audio_decoder.c  2016-03-23 08:37:24.863173759 +0100
45 @@ -204,7 +204,7 @@
46                         packet.data = NULL;
47                         packet.size = 0;
48  
49 -#ifndef FF_API_AVFRAME_LAVC
50 +#if 0
51                         avcodec_get_frame_defaults(audio_input_data->aframe);
52  #else
53                         av_frame_unref(audio_input_data->aframe);
54 @@ -239,7 +239,7 @@
55                 if (packet.stream_index == audio_input_file->astream_idx) {
56                         /* Set audio frame to default */
57  
58 -#ifndef FF_API_AVFRAME_LAVC
59 +#if 0
60                         avcodec_get_frame_defaults(audio_input_data->aframe);
61  #else
62                         av_frame_unref(audio_input_data->aframe);
63 --- gpac/applications/dashcast/audio_encoder.c~ 2014-10-07 23:10:04.000000000 +0200
64 +++ gpac/applications/dashcast/audio_encoder.c  2016-03-23 08:37:37.899978004 +0100
65 @@ -84,7 +84,7 @@
66  
67         audio_output_file->frame_bytes = audio_output_file->codec_ctx->frame_size * av_get_bytes_per_sample(DC_AUDIO_SAMPLE_FORMAT) * DC_AUDIO_NUM_CHANNELS;
68  
69 -#ifndef FF_API_AVFRAME_LAVC
70 +#if 0
71         avcodec_get_frame_defaults(audio_output_file->aframe);
72  #else
73         av_frame_unref(audio_output_file->aframe);
74 --- gpac/applications/dashcast/video_decoder.c~ 2014-10-07 23:10:04.000000000 +0200
75 +++ gpac/applications/dashcast/video_decoder.c  2016-03-23 08:38:02.470233825 +0100
76 @@ -244,7 +244,7 @@
77                         video_data_node->source_number = source_number;
78                         /* Flush decoder */
79                         memset(&packet, 0, sizeof(AVPacket));
80 -#ifndef FF_API_AVFRAME_LAVC
81 +#if 0
82                         avcodec_get_frame_defaults(video_data_node->vframe);
83  #else
84                         av_frame_unref(video_data_node->vframe);
85 @@ -283,7 +283,7 @@
86                         video_data_node->source_number = source_number;
87  
88                         /* Set video frame to default */
89 -#ifndef FF_API_AVFRAME_LAVC
90 +#if 0
91                         avcodec_get_frame_defaults(video_data_node->vframe);
92  #else
93                         av_frame_unref(video_data_node->vframe);
This page took 0.029777 seconds and 3 git commands to generate.