-
Notifications
You must be signed in to change notification settings - Fork 426
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[springbone] SpringBone が無いモデルの NullReferenceException を修正 #2463
[springbone] SpringBone が無いモデルの NullReferenceException を修正 #2463
Conversation
// Vrm10Runtime で初期化していたが、 async にするためこちらに移動 v0.127 | ||
// RuntimeGltfInstance にアクセスしたいのだが OnLoadHierarchy ではまだ attach されてなかった v0.128 | ||
// VRMC_springBone が無くても初期化する v0.127.2 | ||
await m_springboneRuntime.InitializeAsync(controller, awaitCaller); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
VRMC_springBone の有無と無関係に初期化する
{ | ||
m_service = SpringBoneJobs.FastSpringBoneService.Instance; | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
VRMC_springBone が無い時にも InitializeAsync するようにしたので、
無くても大丈夫になったが、初期化を遅延させる意味も無いので constructor。
Unregister(); | ||
var task = RegisterAsync(new ImmediateCaller()); | ||
var _ = RegisterAsync(new ImmediateCaller()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
不要コードの削除など
public Vrm10FastSpringboneRuntime() | ||
{ | ||
m_fastSpringBoneService = FastSpringBones.FastSpringBoneService.Instance; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
VRMC_springBone が無い時にも InitializeAsync するようにしたので、
無くても大丈夫になったが、初期化を遅延させる意味も無いので constructor。
{ | ||
m_fastSpringBoneService.BufferCombiner.Unregister(m_fastSpringBoneBuffer); | ||
m_fastSpringBoneBuffer.Dispose(); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
VRMC_springBone が無い時にも InitializeAsync するようにしたので、
無くても大丈夫になった。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
多段に NullReferenceException の可能性があるのでちょっと整理する。
という API でよさそう。