[PAID]Subtitles Parser Extension: Effortlessly Parse and Manage Subtitles

hello koders ! today I’am introducing my new subtitles Extension for loading and displaying subtitles in an app.

It provides functionality to load subtitles from SRT and SSA files, as well as from URLs. It also includes a method to convert SRT files to SSA format.

Here’s a breakdown of the main blocks and functionalities in the Extension :

Blocks

component_event

SrtConvertedToSsa Event:
This event is triggered when the SRT to SSA conversion is complete. It provides the converted SSA content to the user.




component_event (1)

SubtitlesLoaded Event:
This event is triggered after loading subtitles, allowing the user to handle the loaded subtitles.




component_method

LoadSubtitlesFromFile :
This function loads subtitles from an SRT file. It reads the file, parses the content,




component_method (2)

LoadSubtitlesFromSsaFile : This function loads subtitles from an SSA file. It reads the file, parses the content





component_method (1)


component_method (3)

LoadSrtFromUrl and LoadSsaFromUrl blocks:
These functions load subtitles from SRT and SSA files hosted on a remote server.




component_method (4)

GetSubtitleAtTime:
This function retrieves the subtitle text for a specified time in milliseconds. It iterates through the subtitle entries and checks if the given time falls within the start and end times of each entry.





component_method (5)

ConvertSrtToSsa :
This function converts an SRT file to SSA format. It reads the SRT content, converts it to SSA format using the convertSrtToSsa method, and triggers the SrtConvertedToSsa event with the converted content.


Video

AIX

You can purchase this extension HERE. Once your payment is complete, you will be redirected to the Download URL.


Thanks

Our Telegram Channel

Mr_Koder

10 Likes

Thank you I already make an application to play subtitles on Android STB to watch untranslated movies live
I will try your extension in my application and tell you my feedback

first of all, I am sorry I download your extension before I know it is paid and I will not use it
As I told you in my previous reply I already make an application for this purpose in my application, I use regex extension to parse subtitle files
After I try the extension my notes are
1- block load from file path did not work with me maybe my blocks are wrong
I try load from URL and it works
2- regarding Arabic subtitles if the text has more than one line it read only the first line and the rest of the text does not appear
as the function can be done by regex extension the benefit of your extension is to decrease the time from selecting a subtitle file till loading the sentences list also to decrease the number of blocks
My advice to you it will be better if the outputs of your extension are 3 separate lists
start time
end time
text
as in my application, some people may begin watching the movie after it begins and want to synchronize the subtitle with the movie so I add an option to show all subtitle files sentences in a list view and the user begins to select the right sentence

ok thanks, don’t worry I need you to keep it without sharing.







This block " LoadSubtitlesFromFile :" load only srt file and another one " LoadSubtitlesFromSsaFile" load ssa file make sure to choose right file with right block ,
cause it works fine with me





you are right this problem with srt file I will solve it soon, but it works fine with ssa file try to convert srt file to ssa file and try with it .





ok I will edit this however you can do this with simple combination of blocks in Kodular
cause the output looks like this :

[[start time , end time , text],[start time , end time , text],[start time , end time , text],[start time , end time , text],.....]

Overall thanks @waellotfy77 for your useful feedback, really thanks