Feature: gif mode default repeat infinitely

pull/221/head
xufuji456 2 years ago
parent 92da88c480
commit a121ca291e
  1. 2
      app/src/main/java/com/frank/ffmpeg/gif/BeautyGifEncoder.java
  2. 1
      app/src/main/java/com/frank/ffmpeg/gif/HighQualityGif.kt

@ -24,7 +24,7 @@ public class BeautyGifEncoder {
private int transIndex; // transparent index in color table private int transIndex; // transparent index in color table
private int repeat = -1; // no repeat private int repeat = 0; // repeat infinitely
private int delay = 0; // frame delay private int delay = 0; // frame delay

@ -74,6 +74,7 @@ class HighQualityGif(width: Int, height: Int, rotateDegree: Int) {
val outputStream = ByteArrayOutputStream() val outputStream = ByteArrayOutputStream()
val gifEncoder = BeautyGifEncoder() val gifEncoder = BeautyGifEncoder()
gifEncoder.setRepeat(0)
gifEncoder.setFrameRate(10f) gifEncoder.setFrameRate(10f)
gifEncoder.start(outputStream) gifEncoder.start(outputStream)

Loading…
Cancel
Save