Skip to content

Commit

Permalink
refactor: use lower camel case for variable name
Browse files Browse the repository at this point in the history
  • Loading branch information
rickysixx committed Sep 21, 2024
1 parent a071314 commit 39edb0b
Showing 1 changed file with 12 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@ import org.jellyfin.apiclient.model.dlna.SubtitleProfile
import timber.log.Timber

object ProfileHelper {
private val MediaTest by lazy { MediaCodecCapabilitiesTest() }
private val mediaTest by lazy { MediaCodecCapabilitiesTest() }

val deviceAV1CodecProfile by lazy {
CodecProfile().apply {
type = CodecType.Video
codec = Codec.Video.AV1

conditions = when {
!MediaTest.supportsAV1() -> {
!mediaTest.supportsAV1() -> {
// The following condition is a method to exclude all AV1
Timber.i("*** Does NOT support AV1")
arrayOf(
Expand All @@ -37,7 +37,7 @@ object ProfileHelper {
)
)
}
!MediaTest.supportsAV1Main10() -> {
!mediaTest.supportsAV1Main10() -> {
Timber.i("*** Does NOT support AV1 10 bit")
arrayOf(
ProfileCondition(
Expand All @@ -63,11 +63,11 @@ object ProfileHelper {
}

val supportsAVC by lazy {
MediaTest.supportsAVC()
mediaTest.supportsAVC()
}

val supportsAVCHigh10 by lazy {
MediaTest.supportsAVCHigh10()
mediaTest.supportsAVCHigh10()
}

val deviceAVCCodecProfile by lazy {
Expand Down Expand Up @@ -132,7 +132,7 @@ object ProfileHelper {
ProfileCondition(
ProfileConditionType.LessThanEqual,
ProfileConditionValue.VideoLevel,
MediaTest.getAVCMainLevel()
mediaTest.getAVCMainLevel()
)
)
})
Expand All @@ -154,7 +154,7 @@ object ProfileHelper {
ProfileCondition(
ProfileConditionType.LessThanEqual,
ProfileConditionValue.VideoLevel,
MediaTest.getAVCHigh10Level()
mediaTest.getAVCHigh10Level()
)
)
})
Expand All @@ -164,11 +164,11 @@ object ProfileHelper {
}

val supportsHevc by lazy {
MediaTest.supportsHevc()
mediaTest.supportsHevc()
}

val supportsHevcMain10 by lazy {
MediaTest.supportsHevcMain10()
mediaTest.supportsHevcMain10()
}

fun supportsDts(context: Context, preferFfmpeg: Boolean): Boolean {
Expand Down Expand Up @@ -237,7 +237,7 @@ object ProfileHelper {
ProfileCondition(
ProfileConditionType.LessThanEqual,
ProfileConditionValue.VideoLevel,
MediaTest.getHevcMainLevel()
mediaTest.getHevcMainLevel()
)
)
})
Expand All @@ -259,7 +259,7 @@ object ProfileHelper {
ProfileCondition(
ProfileConditionType.LessThanEqual,
ProfileConditionValue.VideoLevel,
MediaTest.getHevcMain10Level()
mediaTest.getHevcMain10Level()
)
)
})
Expand All @@ -269,7 +269,7 @@ object ProfileHelper {
}

val maxResolutionCodecProfile by lazy {
val maxResolution = MediaTest.getMaxResolution(MediaFormat.MIMETYPE_VIDEO_AVC)
val maxResolution = mediaTest.getMaxResolution(MediaFormat.MIMETYPE_VIDEO_AVC)

CodecProfile().apply {
type = CodecType.Video
Expand Down

0 comments on commit 39edb0b

Please sign in to comment.