pichayuth Posted November 8, 2017 Share Posted November 8, 2017 Dear, All experts I want to create a character creation system like Saint Row game. The Saint Row system allow me to adjust size of each part of the body, such as chest size, arm muscle, legs and arms length. I did some research and the internet said about "Morph" technique. but I still don't understand about what this technique is about, how to do it? how to apply to be used in Babylon? Some said I have to use Blender or 3ds. The information that I got seem to be overwhelming ,but it is like a jigsaw that I don't know where should i begin first. ***Sorry,if i post in the wrong forum or category Thank you in advance Quote Link to comment Share on other sites More sharing options...
JCPalmer Posted November 8, 2017 Share Posted November 8, 2017 Here is the BJS morph target doc. Gotta say though, that this is a very advanced topic for someone who needs to morph in quotes. Not only do you need make max & min targets for each body area, but you need to create the original mesh vertex data. pichayuth 1 Quote Link to comment Share on other sites More sharing options...
Raggar Posted November 8, 2017 Share Posted November 8, 2017 I haven't played SR, but by the looks of it(Google searches), you might be able to use morph targets and different meshes for hair styles. Then different textures as well as skin colors for variation. Look at this example for bone deformation: http://playground.babylonjs.com/#94EHM5 I chose to scale on all axis, although you can scale one at a time. There's an issue with keeping the scale when playing an animation, though. Hmm. Maybe @Deltakosh or @adam know why starting animations reset the scaling on bones. Maybe it's simply not possible? GameMonetize, Dad72 and pichayuth 2 1 Quote Link to comment Share on other sites More sharing options...
adam Posted November 9, 2017 Share Posted November 9, 2017 You have to set the scale in before render every frame when an animation is playing: https://www.babylonjs-playground.com/#1EVNNB#10 Raggar 1 Quote Link to comment Share on other sites More sharing options...
Raggar Posted November 9, 2017 Share Posted November 9, 2017 13 hours ago, adam said: You have to set the scale in before render every frame when an animation is playing: https://www.babylonjs-playground.com/#1EVNNB#10 Ahh. Nice! http://playground.babylonjs.com/#94EHM5#1 Quote Link to comment Share on other sites More sharing options...
pichayuth Posted November 10, 2017 Author Share Posted November 10, 2017 On 11/8/2017 at 11:03 PM, JCPalmer said: Here is the BJS morph target doc. Gotta say though, that this is a very advanced topic for someone who needs to morph in quotes. Not only do you need make max & min targets for each body area, but you need to create the original mesh vertex data. I have read the doc and from what I understand is, if i want to have 3 races in my game (dwarf, human, Orc) which dwarf has a smallest body size and Orc has a biggest one. I have to define a min state as dwarf size and max as Orc size separately for every body part (head, arm, hand, leg, etc) NOT!! The whole body together and the process of defining min and max will be done in modeling program such as Blender Quote Link to comment Share on other sites More sharing options...
natewallis Posted June 12, 2018 Share Posted June 12, 2018 Any ideas why this demo isn't working anymore? http://playground.babylonjs.com/#94EHM5#1 I hit "bigger head" and it caves the head into the body... Quote Link to comment Share on other sites More sharing options...
Raggar Posted June 12, 2018 Share Posted June 12, 2018 5 hours ago, natewallis said: Any ideas why this demo isn't working anymore? http://playground.babylonjs.com/#94EHM5#1 I hit "bigger head" and it caves the head into the body... At some point, the setScale function was changed to require a vector3 instead of 3 separate parameters. This works. I removed the initial scaling of the bones, as it happens in the loop anyway. http://playground.babylonjs.com/#94EHM5#2 Quote Link to comment Share on other sites More sharing options...
natewallis Posted June 12, 2018 Share Posted June 12, 2018 Cool - thanks.. I'll have a play with that. To me it seems that I might get more bang for my buck when it comes to avatar creation by using bone scaling rather than morph targets... Or do you think a bit of both is the best approach? 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.