Skip to content

Commit

Permalink
Change scale_cuda to scale_npp
Browse files Browse the repository at this point in the history
  • Loading branch information
leszko committed Aug 31, 2023
1 parent e8052f0 commit b4d36c9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions ffmpeg/ffmpeg.go
Original file line number Diff line number Diff line change
Expand Up @@ -461,18 +461,18 @@ func configEncoder(inOpts *TranscodeOptionsIn, outOpts TranscodeOptions) (string
if outDev != "" {
upload = upload + "=device=" + outDev
}
return encoder, upload + ",scale_cuda", nil
return encoder, upload + ",scale_npp", nil
}
case Nvidia:
switch outOpts.Accel {
case Software:
return encoder, "scale_cuda", nil
return encoder, "scale_npp", nil
case Nvidia:
// If we encode on a different device from decode then need to transfer
if outDev != "" && outDev != inDev {
return "", "", ErrTranscoderDev // XXX not allowed
}
return encoder, "scale_cuda", nil
return encoder, "scale_npp", nil
}
case Netint:
switch outOpts.Accel {
Expand Down
4 changes: 2 additions & 2 deletions ffmpeg/nvidia_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -550,7 +550,7 @@ func TestNvidia_API_MixedOutput(t *testing.T) {
diff -u $1.md5 ffmpeg_$1.md5
ffmpeg -loglevel warning -i out_$1.ts -c:a aac -ar 44100 -ac 2 \
-vf hwupload_cuda,fps=123,scale_cuda=w=256:h=144 -c:v h264_nvenc \
-vf hwupload_cuda,fps=123,scale_npp=w=256:h=144 -c:v h264_nvenc \
ffmpeg_nv_$1.ts
# sanity check ffmpeg frame count against ours
Expand Down Expand Up @@ -640,7 +640,7 @@ func TestNvidia_API_AlternatingTimestamps(t *testing.T) {
diff -u $1.md5 ffmpeg_$1.md5
ffmpeg -loglevel warning -i out_$1.ts -c:a aac -ar 44100 -ac 2 \
-vf hwupload_cuda,fps=123,scale_cuda=w=256:h=144 -c:v h264_nvenc \
-vf hwupload_cuda,fps=123,scale_npp=w=256:h=144 -c:v h264_nvenc \
-muxdelay 0 -copyts \
ffmpeg_nv_$1.ts
Expand Down

0 comments on commit b4d36c9

Please sign in to comment.