Water Rendering

Everything about development and the OpenMW source code.
corristo
Posts: 495
Joined: 12 Aug 2011, 08:29

Re: Water Rendering

Post by corristo »

my Morrowind.esm doesn't contain any WHGT at all, only Tribunal.esm & Bloodmoon.esm does.
Last edited by corristo on 29 Mar 2012, 22:05, edited 1 time in total.
ezzetabi
Posts: 407
Joined: 03 Feb 2012, 16:52

Re: Water Rendering

Post by ezzetabi »

I am fairly sure it has been added in Tribunal.
corristo
Posts: 495
Joined: 12 Aug 2011, 08:29

Re: Water Rendering

Post by corristo »

Shouldn't water level be read like this?
I tried this, seems working, but lgro still has problems.
User avatar
lgromanowski
Site Admin
Posts: 1193
Joined: 05 Aug 2011, 22:21
Location: Wroclaw, Poland
Contact:

Re: Water Rendering

Post by lgromanowski »

corristo wrote:Shouldn't water level be read like this?
I tried this, seems working, but lgro still has problems.
When I changed Cell::load() method to the one posted by corristo then I have problems with "AMBI":
ERROR: ESM Error: Expected subrecord AMBI but got INTV
File: /home/lgromanowski/.config/openmw/Data Files/Morrowind.esm
Record: CELL
Subrecord: INTV
Offset: 0x3534334
My MW version is v1.5.1629 PL (MW + Bloodmon + Tribunal).
Chris
Posts: 1626
Joined: 04 Sep 2011, 08:33

Re: Water Rendering

Post by Chris »

lgromanowski wrote:My MW version is v1.5.1629 PL (MW + Bloodmon + Tribunal).
Isn't the latest Bloodmoon patch v1.6.1820? Or didn't the Polish release get that one?

EDIT:
Though I do have 1.6, and am getting the error:
ERROR: ESM Error: Expected subrecord WHGT but got INTV
File: ./data/Morrowind.esm
Record: CELL
Subrecord: INTV
Offset: 0x3531684
User avatar
scrawl
Posts: 2152
Joined: 18 Feb 2012, 11:51

Re: Water Rendering

Post by scrawl »

Can you try this one?

Code: Select all

        // Interior cells
        if (esm.isNextSub("INTV") || esm.isNextSub("WHGT"))
            esm.getHT(water);
Chris
Posts: 1626
Joined: 04 Sep 2011, 08:33

Re: Water Rendering

Post by Chris »

That gets it loading, but I'm not seeing any water anywhere (inside or outside). In Beshara, GetWaterLevel returns -nan, while outside returns 0. My screen takes on a blue/greenish hue when I go below the water plane outside, though.
User avatar
scrawl
Posts: 2152
Joined: 18 Feb 2012, 11:51

Re: Water Rendering

Post by scrawl »

this is strange, the WHGT should definitely exist, because even cells in original morrowind have different water heights (beshara: -100, addamasartus: -760)

maybe it is stored somewhere else?
User avatar
werdanith
Posts: 295
Joined: 26 Aug 2011, 16:18

Re: Water Rendering

Post by werdanith »

Chris wrote:That gets it loading, but I'm not seeing any water anywhere (inside or outside). In Beshara, GetWaterLevel returns -nan, while outside returns 0. My screen takes on a blue/greenish hue when I go below the water plane outside, though.
Same, on both desktop and netbook.
User avatar
scrawl
Posts: 2152
Joined: 18 Feb 2012, 11:51

Re: Water Rendering

Post by scrawl »

werdanith, wasn't your interior water working earlier (at the point where jhooks stopped)?

if that is the case, then the difference between your and mine ESM is that it stores WHGT as int, and not float.
Last edited by scrawl on 30 Mar 2012, 10:01, edited 1 time in total.
Post Reply