mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2025-03-19 00:21:40 +00:00
46 lines
1.7 KiB
Diff
46 lines
1.7 KiB
Diff
diff -ru avidemux_2.8.1.orig/avidemux_plugins/ADM_videoEncoder/x265/ADM_x265.cpp avidemux_2.8.1/avidemux_plugins/ADM_videoEncoder/x265/ADM_x265.cpp
|
|
--- avidemux_2.8.1.orig/avidemux_plugins/ADM_videoEncoder/x265/ADM_x265.cpp 2024-10-12 10:07:58.005741891 +0200
|
|
+++ avidemux_2.8.1/avidemux_plugins/ADM_videoEncoder/x265/ADM_x265.cpp 2024-10-12 11:12:13.519781376 +0200
|
|
@@ -205,15 +205,20 @@ again:
|
|
//
|
|
x265_nal *nal;
|
|
uint32_t nbNal = 0;
|
|
- x265_picture pic_out;
|
|
- api->picture_init(¶m,&pic_out);
|
|
+ x265_picture pic_out[MAX_SCALABLE_LAYERS];
|
|
+ x265_picture *pic_out_ptr[MAX_SCALABLE_LAYERS];
|
|
out->flags = 0;
|
|
-
|
|
+
|
|
+ for (int i = 0; i < MAX_SCALABLE_LAYERS; i++)
|
|
+ {
|
|
+ api->picture_init(¶m,&pic_out[i]);
|
|
+ pic_out_ptr[i] = &pic_out[i];
|
|
+ }
|
|
int er;
|
|
if(false==gotFrame)
|
|
{
|
|
ADM_info("Flushing delayed frames\n");
|
|
- er = api->encoder_encode(handle, &nal, &nbNal, NULL, &pic_out);
|
|
+ er = api->encoder_encode(handle, &nal, &nbNal, NULL, pic_out_ptr);
|
|
if(er<=0)
|
|
{
|
|
ADM_info ("End of flush\n");
|
|
@@ -221,7 +226,7 @@ again:
|
|
}
|
|
}else
|
|
{
|
|
- er = api->encoder_encode(handle, &nal, &nbNal, &pic, &pic_out);
|
|
+ er = api->encoder_encode(handle, &nal, &nbNal, &pic, pic_out_ptr);
|
|
if(er<0)
|
|
{
|
|
ADM_error ("[x265] Error encoding %d\n",er);
|
|
@@ -236,7 +241,7 @@ again:
|
|
|
|
|
|
// 3-encode
|
|
- if(false==postAmble(out,nbNal,nal,&pic_out))
|
|
+ if(false==postAmble(out,nbNal,nal,pic_out_ptr[0]))
|
|
{
|
|
ADM_warning("[x265] postAmble failed\n");
|
|
return false;
|