wow.export icon indicating copy to clipboard operation
wow.export copied to clipboard

MH2O bitmap parsing issue.

Open SailorSat opened this issue 4 years ago • 2 comments

In regards to https://github.com/Kruithne/wow.export/issues/195#issuecomment-912125647

I am having issues with exporting water data from WoW Classic.

In relation to the wowdev.wiki entry on ADT/v18...

The full heightmap that covers a whole chunk would be created from 9x9 float values, effectively creating 8x8 quadratic pieces

My understanding of this text and even more so by the provided example is, that the bitmap applies to the quads, not the vertices. Hence the calculation should be width * height bytes - meaning a 8 by 8 chunk would have 64 bits / 8 bytes.

This is also enforced by the offsets in those cases:

"offsetExistsBitmap": 9282, "offsetVertexData": 9290

Aside the fact that (as it is) the exporter reads too many bitmap data there seems to be an offset error somewhere - I've tested with Eastern Kingdoms, adt_30_49 - just below stormwind. nearly EVERY bitmap field comes out as "bitmap": [ 5, 0, 171, 1, 166, 219, 1, 67, 166 ],` which does not seem correct at all.

SailorSat avatar Sep 03 '21 07:09 SailorSat

I've attached a visualization of the bitmap data of adt_30_49 (both wow classic and live wow seem to have the same issue atm.) adt_30_49_visual

SailorSat avatar Sep 03 '21 07:09 SailorSat

One can clearly see the chunks that should have a water bitmap - but the bitmap data for each of those chunks is identical (which seems to be wrong)

SailorSat avatar Sep 03 '21 07:09 SailorSat