hen Posted October 11, 2016 Share Posted October 11, 2016 Hi, i just noticed some bug when attaching skinned meshes at runtime to skeletons. As example: var mySkinnedMesh = mesh[0]; var myOtherSkinnedMesh = mesh[1]; myOtherSkinnedMesh.skeleton = mySkinnedMesh.skeleton; This is working well in v2.4. With the current release, the attached mesh is slightly offset. Quote Link to comment Share on other sites More sharing options...
hen Posted October 11, 2016 Author Share Posted October 11, 2016 Here is a Playground showing the error: http://www.babylonjs-playground.com/#GXIPL#5 Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted October 11, 2016 Share Posted October 11, 2016 There is an error on your PG (setMorph not defined) Quote Link to comment Share on other sites More sharing options...
hen Posted October 11, 2016 Author Share Posted October 11, 2016 20 minutes ago, Deltakosh said: There is an error on your PG (setMorph not defined) Whoops, i forgot to remove a line: http://www.babylonjs-playground.com/#GXIPL#6 This error happens when attaching the skeleton in line 53: "Uncaught TypeError: Failed to execute 'uniformMatrix4fv' on 'WebGLRenderingContext': No function was found that matched the signature provided." Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted October 12, 2016 Share Posted October 12, 2016 Fixed thank you for reporting it Quote Link to comment Share on other sites More sharing options...
hen Posted October 12, 2016 Author Share Posted October 12, 2016 12 minutes ago, Deltakosh said: Fixed thank you for reporting it Thanks! One more question... I developed some simple and lightweight blendshape file format for babylon. Once the recent fix was deployed to the playground you can try it out here: http://www.babylonjs-playground.com/#GXIPL#4 I did not add any guis but you can morph 3 blend targets using the console: morph.setMorph(target, index, weight) morph.setMorph('head', 0, 0.5) morph.setMorph('head', 1, 0.5) morph.setMorph('body', 0, 0.5) Actually i create the files from collada sources within a node.js environment. I cant load my binary parser to the playground, so the example morph files are plain json. After binary conversion they are super small and even with this medium res model its only about 5mb overhead for over 100 blends. Would you might be interested to have this implemented? I could do some class to load the files and to handle blendings. Just i cant change the exporters, but would provide all the infos how the files are made. Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted October 13, 2016 Share Posted October 13, 2016 Actually the best would be to update exporters but in the meantime I'm opposed to have a .babylonblendshape file format. We just need a way to generate them in a convenient way for users. Pinging @JCPalmer as he did something similar for blender and ToB Quote Link to comment Share on other sites More sharing options...
JCPalmer Posted October 13, 2016 Share Posted October 13, 2016 I decided to not represent geometry as data, but rather as computer generated in-line source code. This allowed me to both subclass Mesh (& Skeleton, Bone for that matter), and also allow exporters to specify there own subclasses of QI.Mesh or BABYLON.Mesh. OO just ends with the framework when using JSON. Having subclasses of Mesh with all the messy geometry neatly inside is a much cleaner for implementing my own full featured animation system (position / rotation / morphing / skeleton / audio of Mesh / Camera / Lights), beforerender based. Elegant methods override (like of dispose) are now simple. This makes my code very dependent on Blender and ToB. (Not really an issue in my case). I realized that I wanted a very high degree of control over my destiny very early. Working with the processing of data prior to BJS was a good way to do it, and a perfect way to inject geometry into subclasses. Remember, I am a game developer, and not making tools merely for others. Do not really care if anybody actually uses my extensions. Am in Beta right now. Do have some promotional stuff for public release in the works, but am actually promoting myself as much as the code. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.