问题
I want to create GIF from the existing Video. I have search for related question but I did not find any link which can help me. I was looking for any library or API that can help me to either create bitmaps from the video then again I will create GIF from that bitmap or directly create GIF from the video.
Is there any lib or API to capture sequence of bitmaps from the video?
please give me any link for the library or API that can help me to do this.
回答1:
Take look on JMF (Java Media Framework). It will take you some time to learn basics. Then you will able to do this. I do not have a code sample with me now but as far as I remember you have to create player, then retrieve from it appropriate "control" that provides you access to frames.
Here is an example for start: http://khemsoi.blogspot.com/2006/03/jmf-frame-grabber.html
来源:https://stackoverflow.com/questions/10580056/lib-api-for-create-small-gif-from-video