Page 1 of 1

MakeTarget2

PostPosted: Sun May 26, 2019 12:19 pm
by joepal
Having looked at the existing MakeTarget code and being frustrated with trying to port it to blender 2.80, I have instead started over from scratch.

Instead of developing this as a separate plugin, I have added it as functionality on top of the makehuman plugin for blender (https://github.com/makehumancommunity/m ... or-blender). When using the current master version from github, you'll now get an extra tab "MakeTarget2" alongside the "MakeHuman" one.

maketarget2.png


For now I've only re-implemented the bare minimum of what was available in the old maketarget plugin. I'm not sure anything more is needed, as I think many of the other features have been made superfluous but other changes in the toolset:

  • There's no "load base mesh" button - instead import a human from MH via the "import human" button on the "makehuman" tab
  • There's no functionality for secondary targets - instead apply what you consider to be the primary target in MH before importing
  • There's no symmetrize button. I think you can get this via blender through other means, but it's possible it should be implemented here too.

If you think there's something in the old maketarget that should be ported too, let me know. Otherwise I think is what will become the standard maketarget tool when 1.2.0 is released.

Oh, so you don't get confused: The MakeTarget2 panel will only appear in blender 2.80. I haven't made it play with 2.79 yet. So for 2.79, you'll have to use the old maketarget for now.

Re: MakeTarget2

PostPosted: Thu May 30, 2019 8:17 am
by wolgade
joepal wrote:Having looked at the existing MakeTarget code and being frustrated with trying to port it to blender 2.80, I have instead started over from scratch.

This might be a good idea anyway.
joepal wrote:Instead of developing this as a separate plugin, I have added it as functionality on top of the makehuman plugin for blender

And this might not be the wisest decission. I like your Blender plugin, but it will get harder to use, the more stuff you add to it. When it comes to tools for whatever I prefer one-trick-ponies, which do exactly one thing.
joepal wrote:There's no symmetrize button. I think you can get this via blender through other means,

No, you can't get this through other means in a reliable way. Guessing symmetry in Blender fails frequently. In this specific case there's also no need for guessing. The vertex order of the base mesh is known and won't change. All you need is a table of mirrored vertices. To initially create this table there's existing code written by punkduck.

Re: MakeTarget2

PostPosted: Thu May 30, 2019 1:27 pm
by joepal
wolgade wrote:And this might not be the wisest decission. I like your Blender plugin, but it will get harder to use, the more stuff you add to it. When it comes to tools for whatever I prefer one-trick-ponies, which do exactly one thing.


Yeah. And Rob has already pointed out other reasons for why mixing it into the other blender plugin is a bad idea.

I'll split it into a separate plugin when I continue with it.

wolgade wrote:No, you can't get this through other means in a reliable way. Guessing symmetry in Blender fails frequently. In this specific case there's also no need for guessing. The vertex order of the base mesh is known and won't change. All you need is a table of mirrored vertices. To initially create this table there's existing code written by punkduck.


Ok, I'll force PunkDuck to help me once he's back from vacation. :-)

Re: MakeTarget2

PostPosted: Thu May 30, 2019 1:51 pm
by wolgade
joepal wrote:Ok, I'll force PunkDuck to help me once he's back from vacation. :-)

In the meantime have a look here: https://github.com/black-punkduck/MakeHuman-Helpers/blob/master/create_mirror_tab.py

Re: MakeTarget2

PostPosted: Thu May 30, 2019 1:56 pm
by Aranuvir
The symmetry map is located at makehuman/blendertools/maketarget/symmetry_map.py ...

Re: MakeTarget2

PostPosted: Fri May 31, 2019 12:08 am
by ecke101
I needed to play around with maketarget so I made the changes needed to get it working in 2.80 and a pull request in https://github.com/makehumancommunity/c ... maketarget, maybe you can check it out.

Re: MakeTarget2

PostPosted: Fri May 31, 2019 8:12 am
by joepal
I've merged the pull request. However, it's likely I'm going to rewrite much of the code currently in the maketarget repo based on the discussion above. When/if that happens, I'll keep the code currently in the repo as a separate branch.

Re: MakeTarget2

PostPosted: Sat Jun 08, 2019 11:41 am
by joepal
Working on porting symmetrize. First attempt not very successful...

symmetrize.png

Re: MakeTarget2

PostPosted: Sat Jun 08, 2019 11:56 am
by joepal
Ok, now I've done the following:


maketarget2c.png

Re: MakeTarget2

PostPosted: Sat Jun 08, 2019 6:06 pm
by punkduck
Hmm, I should take a look in here more often. I was busy with other things in between.

As long as we only work with one base mesh, the way Joel did is okay. When we start with different base meshes e.g. like the "extended" version with wings or the newly weighted proxies Elv did etc, then we should start to work with tables instead of using python code. Last not least these tables will be read before according to the mesh we will use, so no or not much difference using the method itself later.