Mert Gedik <[email protected]> wrote: >On Thu, Feb 27, 2014 at 10:16 PM, Anshul <[email protected]> >wrote: > >> >> >> Mert Gedik <[email protected]> wrote: >> >Hello, >> > >> >I've made a video player for iOS using ffmpeg libraries with the >help >> >of >> >dranger tutorial. >> >It is working well, and now I want to add subtitle feature. >> > >> >I know that, ffmpeg can decode internal subtitle stream, and for a >long >> >investigation, I realized that subtitle filter can decode external >> >subtitle. >> > >> >For example, >> >ffplay movie.mp4 -vf subtitles=movie.srt >> > >> >This renders the external subtitle on the screen. I use render word >, >> >as >> >subtitles are drawn on the screen and when I resize to a bigger >frame >> >size, >> >the text resolution becomes lower. >> > >> >What I need is using the ffmpeg subtitle decoders but don't want to >> >render >> >it as fflay does, I want to get decoded subtitle data and show it in >my >> >UILabel. >> > >> >Is there a way to do this ? >> > >> >Thanks for helping, >> > >> >Regards, >> > >> >-MG >> > >> > >> >>------------------------------------------------------------------------ >> > >> >_______________________________________________ >> >Libav-user mailing list >> >[email protected] >> >http://ffmpeg.org/mailman/listinfo/libav-user >> >> Srt files are simple text file with there timing, if you have time of >each >> audio frame, then at the same time u can read srt file directly and >at >> correct time you can change ur ui label. >> -- >> Sent from my Android device with K-9 Mail. Please excuse my brevity. >> _______________________________________________ >> Libav-user mailing list >> [email protected] >> http://ffmpeg.org/mailman/listinfo/libav-user >> > > > >Yes ,that's right how ever there are many subtitle formats and >I don't want to implement every subtitle parser by myself ... >Ffmpeg has already many decoders for subtitles, therefore I want to >find an >easy way to pass subtitle file to ffmpeg. > >but how to do this ? > > >------------------------------------------------------------------------ > >_______________________________________________ >Libav-user mailing list >[email protected] >http://ffmpeg.org/mailman/listinfo/libav-user I have never tried but still i would advice you look for transcoding the subtitle in srt if i understand u well, u need time and text to show in ur personal ui label.
I use drawtext filter with automatic font size that adjust according to text length. If you have only the problem of fontsize at the time of high resolution you can try workaround using drawtext filter. If you have time u can look in subtitle filter and check if it is possible to add fontsize option. If it is possible can u link me how u r displaying the frames where font size is very small.(code) -Anshul -- Sent from my Android device with K-9 Mail. Please excuse my brevity. _______________________________________________ Libav-user mailing list [email protected] http://ffmpeg.org/mailman/listinfo/libav-user
