castle-model-viewer icon indicating copy to clipboard operation
castle-model-viewer copied to clipboard

Model converted by x3d-tidy views correctly in Sunrize, but not CMV

Open coderextreme opened this issue 6 months ago • 9 comments

Please try to view this model in castle-model-viewer or report problem with model.

I’m trying to get this model viewing in general (beyond Sunrize). I don’t know if it validates yet, so please be patient as I do that sometime today.

It should pass castle model viewer checks.

https://github.com/coderextreme/HAnimUtilityKit/blob/main/WalkingAlienFinalOutputX_ITE.x3dv

Thanks!

coderextreme avatar Sep 01 '25 21:09 coderextreme

The viewer doesn't report any problem, and castle-model-converter --validate WalkingAlienFinalOutputX_ITE.x3dv goes OK.

However the animation looks very weird / buggy. I understand the animation is correct in Sunrize, so this requires investigation -- and may be some bug on our side.

michaliskambi avatar Sep 01 '25 22:09 michaliskambi

Thanks for your efforts, and Joe thanks you, too!

John On Mon, Sep 1, 2025 at 5:46 PM Michalis Kamburelis @.***> wrote:

michaliskambi left a comment (castle-engine/castle-model-viewer#118) https://github.com/castle-engine/castle-model-viewer/issues/118#issuecomment-3243346059

The viewer doesn't report the problem but the animation looks very weird / buggy.

I understand the animation is correct in Sunrize, so this requires investigation -- and may be some bug on our side.

— Reply to this email directly, view it on GitHub https://github.com/castle-engine/castle-model-viewer/issues/118#issuecomment-3243346059, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFMJ536GXRE35H35HMP4ST3QTEFFAVCNFSM6AAAAACFLLW4NSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTENBTGM2DMMBVHE . You are receiving this because you authored the thread.Message ID: @.***>

coderextreme avatar Sep 01 '25 22:09 coderextreme

Maybe try some of the other animations in the file to see if they are better.

I understand that not all Joints probably have the exact right DEFs, but AFAIK, that didn’t stop me before.

John

On Mon, Sep 1, 2025 at 5:46 PM Michalis Kamburelis @.***> wrote:

michaliskambi left a comment (castle-engine/castle-model-viewer#118) https://github.com/castle-engine/castle-model-viewer/issues/118#issuecomment-3243346059

The viewer doesn't report the problem but the animation looks very weird / buggy.

I understand the animation is correct in Sunrize, so this requires investigation -- and may be some bug on our side.

— Reply to this email directly, view it on GitHub https://github.com/castle-engine/castle-model-viewer/issues/118#issuecomment-3243346059, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFMJ536GXRE35H35HMP4ST3QTEFFAVCNFSM6AAAAACFLLW4NSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTENBTGM2DMMBVHE . You are receiving this because you authored the thread.Message ID: @.***>

coderextreme avatar Sep 01 '25 23:09 coderextreme

One important point is, this is the only .glTF model I am converting. I can try converting more .glTF models with Holger’s x3d-tidy. Maybe that might narrow the issue?

I might have some old models here, on my old machine:

https://github.com/coderextreme/HAnimDecoratorAssembly https://github.com/coderextreme/HAnimDecoratorAssembly/blob/main/convertGramps.sh /

They are huge, compared to WalkingAlien.gltf. I can set up GItHub LFS and check them in.

John

On Mon, Sep 1, 2025 at 6:14 PM John Carlson @.***> wrote:

Maybe try some of the other animations in the file to see if they are better.

I understand that not all Joints probably have the exact right DEFs, but AFAIK, that didn’t stop me before.

John

On Mon, Sep 1, 2025 at 5:46 PM Michalis Kamburelis < @.***> wrote:

michaliskambi left a comment (castle-engine/castle-model-viewer#118) https://github.com/castle-engine/castle-model-viewer/issues/118#issuecomment-3243346059

The viewer doesn't report the problem but the animation looks very weird / buggy.

I understand the animation is correct in Sunrize, so this requires investigation -- and may be some bug on our side.

— Reply to this email directly, view it on GitHub https://github.com/castle-engine/castle-model-viewer/issues/118#issuecomment-3243346059, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFMJ536GXRE35H35HMP4ST3QTEFFAVCNFSM6AAAAACFLLW4NSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTENBTGM2DMMBVHE . You are receiving this because you authored the thread.Message ID: @.***>

coderextreme avatar Sep 01 '25 23:09 coderextreme

It appears that this model has only translations, no centers for Joints!

I will work on a translation to center mapping.

John

On Mon, Sep 1, 2025 at 6:23 PM John Carlson @.***> wrote:

One important point is, this is the only .glTF model I am converting. I can try converting more .glTF models with Holger’s x3d-tidy. Maybe that might narrow the issue?

I might have some old models here, on my old machine:

https://github.com/coderextreme/HAnimDecoratorAssembly https://github.com/coderextreme/HAnimDecoratorAssembly/blob/main/convertGramps.sh /

They are huge, compared to WalkingAlien.gltf. I can set up GItHub LFS and check them in.

John

On Mon, Sep 1, 2025 at 6:14 PM John Carlson @.***> wrote:

Maybe try some of the other animations in the file to see if they are better.

I understand that not all Joints probably have the exact right DEFs, but AFAIK, that didn’t stop me before.

John

On Mon, Sep 1, 2025 at 5:46 PM Michalis Kamburelis < @.***> wrote:

michaliskambi left a comment (castle-engine/castle-model-viewer#118) https://github.com/castle-engine/castle-model-viewer/issues/118#issuecomment-3243346059

The viewer doesn't report the problem but the animation looks very weird / buggy.

I understand the animation is correct in Sunrize, so this requires investigation -- and may be some bug on our side.

— Reply to this email directly, view it on GitHub https://github.com/castle-engine/castle-model-viewer/issues/118#issuecomment-3243346059, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFMJ536GXRE35H35HMP4ST3QTEFFAVCNFSM6AAAAACFLLW4NSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTENBTGM2DMMBVHE . You are receiving this because you authored the thread.Message ID: @.***>

coderextreme avatar Sep 02 '25 01:09 coderextreme

The translation to center mapping works, plus I default translation and rotation in HAnimJoints.

coderextreme avatar Sep 05 '25 02:09 coderextreme

I will close this issue if no further analysis is required!

coderextreme avatar Nov 15 '25 03:11 coderextreme

It is a valid bugreport -- if the animation works in Sunrize and doesn't work in Castle Model Viewer, that's something I'd like to fix.

I saw that the testcase linked in the description https://github.com/coderextreme/HAnimUtilityKit/blob/main/WalkingAlienFinalOutputX_ITE.x3dv is no longer available, it was deleted from the repository. But I can find it looking in repo history, at September 1st, https://github.com/coderextreme/HAnimUtilityKit/blob/2438ee5a90356986ede911807ea7082661a8b503/WalkingAlienFinalOutputX_ITE.x3dv .

So, please leave this open. I will want to eventually investigate it. Sorry it takes time, there's too many tasks I try to do :)

michaliskambi avatar Nov 15 '25 19:11 michaliskambi

Possible reason for failure: model from https://github.com/coderextreme/HAnimUtilityKit/blob/main/WalkingAlienFinalOutputX_ITE.x3dv relies on HAnimHumanoid.jointBindingPositions, it has:

  jointBindingPositions [
    0 0 0,
    0 0 0,
    -0 -82.478 -1.859,
    -0 -89.597 -3.1794,
    -0 -93.79 -3.1975,
    -0 -97.766 -2.832,
    -0 -103.1 -2.2463,
...

And we don't handle HAnimHumanoid.jointBindingPositions yet.

I will look into fixing this soon.

michaliskambi avatar Nov 26 '25 23:11 michaliskambi