niftools and blender plugin

OpenMW's very own demo, template and game to show off everything that OpenMW is capable of.

Moderator: Example suite forum moderator

User avatar
Frik
Posts: 124
Joined: 20 Dec 2016, 05:22

Re: niftools and blender plugin

Post by Frik »

psi29a wrote:I would rather just link (path name) to a texture external of a nif since it would be easier to test and adjust.
I agree. I'd rather use an external texture, as well.

Being that nifskope was showing the texture as having a .tga extension and I couldn't find any textures with .tga extensions, I assumed the texture was embedded. That was an incorrect assumption. For example, Nifskope was showing a texture as Tx_wood_interior_plain.tga, but the external file that's actually being loaded was Tx_wood_interior_plain.dds. That was a little confusing for me. :mrgreen:
User avatar
psi29a
Posts: 5355
Joined: 29 Sep 2011, 10:13
Location: Belgium
Gitlab profile: https://gitlab.com/psi29a/
Contact:

Re: niftools and blender plugin

Post by psi29a »

OK, I managed to assign a texture via material on my mesh in blender 2.77 and have it exported as a NIF. It does so by path however, it does not embed the texture into the NIF. It has to be UV mapped, if not it will complain about it. ;)

Nifscope says:
NiNode -> NiTriShape -> NiTexturingProperty -> NiSourceTexture = texture.dds

The only odd part is that it will replace your texture's extension with dds, so filename.png will become filename.dds

You can use Nifscope to change the filename to say texture.png

OpenMW supports more than just dds and tga btw, so feel free to use others, png for example. :)
User avatar
Capostrophic
Posts: 794
Joined: 22 Feb 2016, 20:32

Re: niftools and blender plugin

Post by Capostrophic »

> png for example

But there's a "but": if a dds texture is present, textures with the same file name in other formats are ignored.
User avatar
psi29a
Posts: 5355
Joined: 29 Sep 2011, 10:13
Location: Belgium
Gitlab profile: https://gitlab.com/psi29a/
Contact:

Re: niftools and blender plugin

Post by psi29a »

That's is OpenMW taking your dds over your other file. It does this because dds can be directly uploaded to the GPU instead of having OSG go through an extra step. A gotcha of the OpenMW engine.
User avatar
silentthief
Posts: 456
Joined: 18 Apr 2013, 01:20
Location: Currently traversing the Ascadian Isles

Re: niftools and blender plugin

Post by silentthief »

psi29a wrote:That's is OpenMW taking your dds over your other file. It does this because dds can be directly uploaded to the GPU instead of having OSG go through an extra step. A gotcha of the OpenMW engine.
iirc, vanilla MW did this as well...???

ST
User avatar
Pherim
Posts: 140
Joined: 27 Aug 2014, 15:37

Re: niftools and blender plugin

Post by Pherim »

Frik wrote:Looking at some other vanilla models in nifskope, It appears that all the texture file extensions in those .nif files were .tga. Can I assume the game engine falls back or simply loads up a .dds whenever it encounters the .tga extension?
The game can use both .tga and .dds files, but will use .dds over .tga, even if both are present.
User avatar
Frik
Posts: 124
Joined: 20 Dec 2016, 05:22

Re: niftools and blender plugin

Post by Frik »

Yeah. I finally figured that out. It does make sense to use .dds, when possible. It's just not everyday that I see an exact filename specified, yet a file with a different name gets loaded. 8-)
User avatar
sjek
Posts: 442
Joined: 22 Nov 2014, 10:51

Re: niftools and blender plugin

Post by sjek »

psi29a wrote:I find it curious that instead of wanting to improve niftools that they decided to go at it alone.
viewtopic.php?f=4&t=3526&start=200#p45283

wouldn't say alone xP vague memory is that it's easier to write it droundup than fight with niftools multigame support

edit: maybe i can put this here as examplesuite goes near modding morrowind https://www.youtube.com/watch?v=xzszrMoGJ18 althought videos were made just recently
User avatar
psi29a
Posts: 5355
Joined: 29 Sep 2011, 10:13
Location: Belgium
Gitlab profile: https://gitlab.com/psi29a/
Contact:

Re: niftools and blender plugin

Post by psi29a »

I've been in contact with G7 last week. The reason he went at it alone is because he didn't want to be bother with having to tip-toe around other formats and versions that niftools also supports only to focus on Morrowind support.

His work so far is actually pretty good, he has been putting a lot of effort into animation support.

After talking with him further, he was pretty receptive to working with me on getting Niftool's Blender Plugin back on track. So, thanks to Destined for getting us together. ;)

I have a few fixes in the queue now, but we still have a ways to go. The 'fixes' are easy, it is the test-cases and documentation that takes a lot of time. ;)
Post Reply