Jump to content

[WIP] BodyMorph


Expired6978

Recommended Posts

Zaps

 

One problem you will run into as you implement actual outfits are meshes that require zap sliders.

I doubt this functionality can be reimplemented in-game, so these meshes need to be zapped before

being used as BodyMorph sources. Or not zapped at all, in case it's an optional zap.

 

So what happens when a zap is applied? Well, some vertices and everything associated with them

(faces, uvs, normals, weighting, and whatnot) is removed from the output nif. Normal sliders applies

before zaps in Bodyslide, and obviously they will not work when their respective shape has been

zapped, because the vertex count and order is modified.

 

Not to worry though, I can probably write a function that reorders bsd files to work with the zapped nif.

While at it, it might be interesting to make another that builds your tri-like archives from selected bsd

files, optionally cleaning away zap-data. You already have a tool for the first, but perhaps it can be

improved? Might even be possibly to batch-convert complete groups. I would use existing batch

data files for that (like the ones bundled with Bodyslide_tools), because parsing existing slidersets

is a PITA, haven't been able to do that yet.

 

Link to comment

Zaps

 

One problem you will run into as you implement actual outfits are meshes that require zap sliders.

I doubt this functionality can be reimplemented in-game, so these meshes need to be zapped before

being used as BodyMorph sources. Or not zapped at all, in case it's an optional zap.

 

So what happens when a zap is applied? Well, some vertices and everything associated with them

(faces, uvs, normals, weighting, and whatnot) is removed from the output nif. Normal sliders applies

before zaps in Bodyslide, and obviously they will not work when their respective shape has been

zapped, because the vertex count and order is modified.

 

Not to worry though, I can probably write a function that reorders bsd files to work with the zapped nif.

While at it, it might be interesting to make another that builds your tri-like archives from selected bsd

files, optionally cleaning away zap-data. You already have a tool for the first, but perhaps it can be

improved? Might even be possibly to batch-convert complete groups. I would use existing batch

data files for that (like the ones bundled with Bodyslide_tools), because parsing existing slidersets

is a PITA, haven't been able to do that yet.

Yes, that would be great, generating the tri-like files. Even better to auto attach them as well, but that uses an expected file path so unless they are exported to a known path it wouldn't be able to know where they go generically. I haven't looked at all of the available ExtraData types and their structures, but it may even be possible to just bake the tri-like data right into the mesh via some ExtraData.

 

I can change the format or do whatever with it, it just has to outline how and what vertices to move. As for zapping I could probably actually zap in-game as long as the format was refined to outline how and what to do with the original data. It's essentially just all the the nif data at runtime, and it's loaded and altered before rendering occurs so actually removing elements should be possible.

 

Easiest would be to work with post-zap though since I assume it would just be moving vertex coordinates as it does now rather than deleting or moving them.

Link to comment

Yes, that would be great, generating the tri-like files. Even better to auto attach them as well, but that uses an expected file path so unless they are exported to a known path it wouldn't be able to know where they go generically. I haven't looked at all of the available ExtraData types and their structures, but it may even be possible to just bake the tri-like data right into the mesh via some ExtraData.

 

 

I haven't actually modified nifs in any way, so adding data is not an option for me. Besides, external data is more flexible.

 

I can change the format or do whatever with it, it just has to outline how and what vertices to move. As for zapping I could probably actually zap in-game as long as the format was refined to outline how and what to do with the original data. It's essentially just all the the nif data at runtime, and it's loaded and altered before rendering occurs so actually removing elements should be possible.

 

Easiest would be to work with post-zap though since I assume it would just be moving vertex coordinates as it does now rather than deleting or moving them.

 

 

Oh, didn't know that. In that case it might be possible to recreate all of Bodyslide with BodyMorph. As for what zap sliders do

in detail, probably only Caliente knows, if even she... much of the code could just be niflib calls.

 

I'll take a stab at reordering sliders first, as soon as I get enough free time. No ETA. :shy:

 

 

Link to comment

Just moving vertices around is definitely easier though, you could probably bake it right into the mesh by using niflib to create one NiStringsExtraData as the master naming it BODYMORPH or something, which would be a list of all the sliders, then create 3 NiFloatsExtraData (Or one NiIntegersExtraData and 3 NiFloatsExtraData to map changing indices rather than all indices) per NiTriShapeData and then name them after the slider. This would essentially be enough to re-create the BSD format using just nif ExtraData, and no external files would be necessary as the data would be right in the mesh, I would just need to alter the Body TRI loader to interpret this data instead.

 

There are also other ExtraData types that might be more suitable, I haven't looked at them all yet, I think there might even be just a plain binary data one.

Link to comment
  • 4 weeks later...
  • 2 months later...

Wow, all sliders info in ExtraData sounds so fking awesome!

 

No 3rd party tools (for users), no hassle, just single NIF file that has bodyslide sliders build in - what to want more?

 

And if thats not enough, NPCs could be scaled separately from player?

 

Why this thing isnt more popular yet?

Link to comment

Wow, all sliders info in ExtraData sounds so fking awesome!

 

No 3rd party tools (for users), no hassle, just single NIF file that has bodyslide sliders build in - what to want more?

 

And if thats not enough, NPCs could be scaled separately from player?

 

Why this thing isnt more popular yet?

Dunno, only one or two people have taken interest. I haven't fixed the update problem yet, when the mesh morphs it needs to tell the renderer to redraw it, but I haven't figured out the native process to do this correctly yet.

Link to comment
  • 5 weeks later...

I thought about trying this method (as replacement for node scaling), but since it requires an UpdateWeight function, that isnt so lightweight when used on player and is not updating neck delta for npcs (not sure if neck delta matters here?), I guess its not intended to do real-time modifications on multiple actors? Or did you find some other way to update since then?

Link to comment

I thought about trying this method (as replacement for node scaling), but since it requires an UpdateWeight function, that isnt so lightweight when used on player and is not updating neck delta for npcs (not sure if neck delta matters here?), I guess its not intended to do real-time modifications on multiple actors? Or did you find some other way to update since then?

There should be a function that tells the engine to invalidate the mesh's vertex shaders to re-render the object, but I haven't found it yet. The neck delta adjustment is a function on its own, but it only acts relatively which is highly dependent on the state prior to movement. You can't tell the state because it's baked into the vertex data and there's no way to recover the numeric weight, so the only thing you can do is assume for the first load, and store it for all consecutive loads.

Link to comment

No, I meant that UpdateWeight's neckDelta wasnt working for me at all (if used on non player actors), but since the bodyslide sliders arent modyfing that area it should be safe to ignore neckDelta param in that case and just use it to update the rest of the body, right?

 

Other thing was UpdateWeight causing 1sec freeze, but only when used on player (must be computing something heavy for player only, like the whole head data or something).

 

It makes it usable in specific cases when you modify the sliders once per load (like RaceMenu), but otherwise not so much. Waiting for faster function then. :)

 

 

Link to comment
  • 6 months later...

ah I see, would of being a lot more great if it worked for npcs, since the possibility of having a wide range of body types for different npcs without going back and forth editing their actual body files.  well still awesome job getting it to work for the player, this type  of mods are always appreciated by the community.

Link to comment

Guys, I am sorry to bother you, but with my english I can't correctly understand what mean Body morph in Skyrim? Actually I can't understand what I can do with body in this mod? I thought morphing is changing vertex positions from femalebody_0 to femalebody_1 or using sliders to increase the size of body parts by increasing bones size in racemenu. So, maybe this tool can create  femalebody_0 which will work with custom femalebody_1? I hope someone can told me on example for what purposes you can use this bodymorph tool.

 Thank you for your attention.

Link to comment
  • 2 months later...
  • 1 month later...

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more information, see our Privacy Policy & Terms of Use