Chapter & Subtitle
Chapter Class
com.kollus.sdk.media.content.KollusContent.ChapterInfo.Chapter
A class that manages detailed information about a chapter, which defines a specific point in the content.
Public Methods
int getPosition()String getValue()
Method Details
int com.kollus.sdk.media.content.KollusContent.ChapterInfo.Chapter.getPosition()
Returns the time at which the chapter starts within the entire video.
- Returns: Chapter start time (sec)
String com.kollus.sdk.media.content.KollusContent.ChapterInfo.Chapter.getValue()
Returns the name or description of the chapter. Used as the text displayed in the player's chapter list.
- Returns: Chapter name or description
ChapterInfo Class
com.kollus.sdk.media.content.KollusContent.ChapterInfo
A class that manages the chapter data set of the content. Includes a specific language setting and a detailed chapter list written in that language.
Public Methods
List<Chapter> getChapters()String getLanguage()
Method Details
List<Chapter> com.kollus.sdk.media.content.KollusContent.ChapterInfo.getChapters()
Returns the list of chapters defined in the content.
- Returns: Chapter list
String com.kollus.sdk.media.content.KollusContent.ChapterInfo.getLanguage()
Returns the language code set for the chapter set. Used to distinguish chapters by language for content that supports multiple languages.
- Returns: Language code
OnTimedTextDetectListener Interface
com.kollus.sdk.media.MediaPlayer.OnTimedTextDetectListener
An interface that receives the status when a subtitle added via addTimedTextSource() or a subtitle embedded in the media stream is detected.
Public Methods
void onSubTimedTextDetect(MediaPlayer mp, int trackIndex)void onTimedTextDetect(MediaPlayer mp, int trackIndex)
Method Details
void com.kollus.sdk.media.MediaPlayer.OnTimedTextDetectListener.onSubTimedTextDetect(MediaPlayer mp, int trackIndex)
Called when a playable sub subtitle is found in the content.
- Parameters
mp: Player instancetrackIndex: Subtitle index
void com.kollus.sdk.media.MediaPlayer.OnTimedTextDetectListener.onTimedTextDetect(MediaPlayer mp, int trackIndex)
Called when a playable main subtitle is found in the content.
- Parameters
mp: Player instancetrackIndex: Subtitle index
OnTimedTextListener Interface
com.kollus.sdk.media.MediaPlayer.OnTimedTextListener
An interface that receives subtitle data synchronized to the playback timeline.
Public Methods
void onSubTimedText(MediaPlayer mp, String text)void onTimedImage(MediaPlayer mp, byte[] image, int width, int height)void onTimedText(MediaPlayer mp, String text)
Method Details
void com.kollus.sdk.media.MediaPlayer.OnTimedTextListener.onSubTimedText(MediaPlayer mp, String text)
Called when text-format sub subtitle data is received.
- Parameters
mp: Player instancetext: Sub subtitle string corresponding to the current playback position
void com.kollus.sdk.media.MediaPlayer.OnTimedTextListener.onTimedImage(MediaPlayer mp, byte[] image, int width, int height)
Called when image-format subtitle (VobSub) data is received.
- Parameters
mp: Player instanceimage: Bitmap data of the subtitle imagewidth: Width of the subtitle imageheight: Height of the subtitle image
void com.kollus.sdk.media.MediaPlayer.OnTimedTextListener.onTimedText(MediaPlayer mp, String text)
Called when text-format main subtitle data is received.
- Parameters
mp: Player instancetext: Main subtitle string corresponding to the current playback position
SubtitleInfo Class
com.kollus.sdk.media.content.KollusContent.SubtitleInfo
A class that manages metadata for individual subtitles included in the content.
Public Properties
String nameString urlString languageCodeboolean ai
Property Details
| Property | Type | Description |
|---|---|---|
languageCode | String | Language code of the subtitle |
name | String | Language name of the subtitle |
url | String | Resource path for loading the subtitle data |
ai | boolean | Whether the subtitle was generated by the AI Subtitle service |