Support bounded 720x1280 avatar shapes through GLES and production gates

This commit is contained in:
zenord
2026-10-13 17:32:21 +08:00
parent 62dce32bb7
commit ddd75fc571
18 changed files with 352 additions and 83 deletions
+11 -2
View File
@@ -31,9 +31,10 @@ fun startupCacheCheck() {
fun startupViewCheck() {
var cases=0
fun rig(): Triple<StartupAvatarView,ContinuousAvatarPack,AvatarPack> {
fun rig(width: Int=480,height: Int=848): Triple<StartupAvatarView,ContinuousAvatarPack,AvatarPack> {
TestScheduler.reset();CodecFixture.reset();CodecFixture.emitNativeSurface=true
val index=mediaFixtureIndex();val neutral=index.packages.getValue(index.fallbackId)
CodecFixture.width=width;CodecFixture.height=height
val index=mediaFixtureIndex(width,height);val neutral=index.packages.getValue(index.fallbackId)
index.packages.values.forEach { CodecFixture.timelines[it.root+it.body.path]=it.body.ptsUs }
index.edges.mapNotNull {it.mouthRuntime}.forEach {CodecFixture.timelines[it.root+it.body.path]=it.body.ptsUs}
return Triple(StartupAvatarView(android.content.Context(),AvatarMediaBinding(),{},{}),neutral.copy(patches=emptyList(),curves=emptyMap()),AvatarPack(fallback="fixture.png",emotionAction=index))
@@ -64,5 +65,13 @@ fun startupViewCheck() {
retrying.update(b4,p4,true,"failed");CodecFixture.configureFails=false
retrying.update(b4,p4,true,"preparing");TestScheduler.until(6000) { recovered==1 };cases++
retrying.dispose();TestScheduler.advanceBy(100)
val (large,largeBase,largeFull)=rig(720,1280)
large.update(largeBase,null,true);TestScheduler.advanceBy(250)
large.update(largeBase,largeFull,true);TestScheduler.advanceBy(100)
check((large.children.last() as EmotionActionAvatarView).alpha==0f);cases++
TestScheduler.until(6000) { (large.children.last() as EmotionActionAvatarView).alpha==1f }
TestScheduler.until(100) { CodecFixture.releases>=1 }
check(android.opengl.GLFixture.bodySize==720f to 1280f);cases++
large.dispose();TestScheduler.advanceBy(100)
println("PASS: $cases production startup host renderer callback cases: held exact target0/source0, decoderrelease before capability, persistent host, lifecycle and bodySHA mismatch")
}