File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
package/shared-native/android Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -14,8 +14,8 @@ data class StreamVideoThumbnailResult(
1414)
1515
1616object StreamVideoThumbnailGenerator {
17- private const val DEFAULT_COMPRESSION_QUALITY = 80
18- private const val DEFAULT_MAX_DIMENSION = 512
17+ private const val DEFAULT_COMPRESSION_QUALITY = 70
18+ private const val DEFAULT_MAX_DIMENSION = 256
1919 private const val CACHE_VERSION = " v1"
2020 private const val CACHE_DIRECTORY_NAME = " @stream-io-stream-video-thumbnails"
2121 private const val MAX_CONCURRENT_GENERATIONS = 5
@@ -64,7 +64,7 @@ object StreamVideoThumbnailGenerator {
6464 return try {
6565 setDataSource(retriever, context, url)
6666 val frame =
67- retriever.getFrameAtTime(0 , MediaMetadataRetriever .OPTION_CLOSEST_SYNC )
67+ retriever.getFrameAtTime(100000 , MediaMetadataRetriever .OPTION_CLOSEST_SYNC )
6868 ? : throw IllegalStateException (" Failed to extract video frame for $url " )
6969 val scaledFrame = scaleBitmap(frame)
7070
You can’t perform that action at this time.
0 commit comments