shahen94 / react-native-video-processing

Native Video editing/trimming/compressing :movie_camera: library for React-Native
https://shahen94.github.io/react-native-video-processing/
MIT License
1.25k stars 326 forks source link

getPreviewForSecond() Screenshot does not match actual video image   #266

Open maomeiqi opened 4 years ago

maomeiqi commented 4 years ago
ProcessingManager.getVideoInfo(source)
        .then((info) => {
            this.setStart({
                 videoInfo:info
             })
        });
console.debug('Video information:'+JSON.stringify(this.start.videoInfo));
console.debug('Selected screenshot time:'+this.state.currentTime)
 ProcessingManager.getPreviewForSecond(voideUrl,this.state.currentTime, {},'JPEG')
    .then((data) => {
        console.debug(data.uri)
      })
     .catch((err)=>{console.debug(err,'getPreviewForSecondErr')})

Expected result: Get the image of the last frame of the video

Actual effect: Screenshot does not match actual video image

image

software version
react-native-video-processing 1.20.0
react-native 0.61.5
node 10.15.3
illiteratewriter commented 3 years ago

@maomeiqi have you found a solution to this issue?