add chinese subtitles
This commit is contained in:
@@ -159,6 +159,11 @@ class SentenceBoundaryApi internal constructor(
|
||||
} else {
|
||||
sentence.getLong("reference_speech_duration_ms")
|
||||
},
|
||||
zhText = if (sentence.isNull("zh_text")) {
|
||||
null
|
||||
} else {
|
||||
sentence.getString("zh_text").takeIf { it.isNotBlank() }
|
||||
},
|
||||
)
|
||||
)
|
||||
}
|
||||
|
||||
@@ -10,6 +10,7 @@ data class SentenceBoundary @JvmOverloads constructor(
|
||||
val text: String? = null,
|
||||
val language: String? = null,
|
||||
val referenceSpeechDurationMs: Long? = null,
|
||||
val zhText: String? = null,
|
||||
) {
|
||||
init {
|
||||
require(index >= 0) { "Sentence index must be non-negative." }
|
||||
|
||||
Reference in New Issue
Block a user