Browse Source

Move try

igor.demin/new-york-bench-without-window
Igor Demin 1 year ago
parent
commit
37d0f7226b
  1. 8
      benchmarks/ios/visual-effects-ny/shared/src/commonMain/kotlin/HappyNY.kt

8
benchmarks/ios/visual-effects-ny/shared/src/commonMain/kotlin/HappyNY.kt

@ -340,11 +340,11 @@ fun measureHappyNY(
frameCount: Int = 1000
): Duration {
val scene = ComposeScene()
scene.setContent {
NYContent()
}
val surface = org.jetbrains.skia.Surface.makeNull(width, height)
try {
scene.setContent {
NYContent()
}
val surface = org.jetbrains.skia.Surface.makeNull(width, height)
return kotlin.time.measureTime {
var nanoTime = 0L
repeat(frameCount) {

Loading…
Cancel
Save