Skip to content

Commit 107918b

Browse files
committed
Adding more debugging / logging to hardware acceleration
1 parent b874e91 commit 107918b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/FFmpegReader.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,7 @@ void FFmpegReader::Open() {
213213
pFormatCtx = NULL;
214214
{
215215
hw_de_on = (openshot::Settings::Instance()->HARDWARE_DECODER == 0 ? 0 : 1);
216+
ZmqLogger::Instance()->AppendDebugMethod("Decode hardware acceleration settings", "hw_de_on", hw_de_on, "HARDWARE_DECODER", openshot::Settings::Instance()->HARDWARE_DECODER);
216217
}
217218

218219
// Open video file
@@ -1177,10 +1178,10 @@ bool FFmpegReader::GetAVFrame() {
11771178
if (next_frame2->format == hw_de_av_pix_fmt) {
11781179
next_frame->format = AV_PIX_FMT_YUV420P;
11791180
if ((err = av_hwframe_transfer_data(next_frame,next_frame2,0)) < 0) {
1180-
ZmqLogger::Instance()->AppendDebugMethod("FFmpegReader::GetAVFrame (Failed to transfer data to output frame)");
1181+
ZmqLogger::Instance()->AppendDebugMethod("FFmpegReader::GetAVFrame (Failed to transfer data to output frame)", "hw_de_on", hw_de_on);
11811182
}
11821183
if ((err = av_frame_copy_props(next_frame,next_frame2)) < 0) {
1183-
ZmqLogger::Instance()->AppendDebugMethod("FFmpegReader::GetAVFrame (Failed to copy props to output frame)");
1184+
ZmqLogger::Instance()->AppendDebugMethod("FFmpegReader::GetAVFrame (Failed to copy props to output frame)", "hw_de_on", hw_de_on);
11841185
}
11851186
}
11861187
}

0 commit comments

Comments
 (0)