Skip to content
View in the app

A better way to browse. Learn more.

ResHax

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.
Help us keep the site running.

xbox ps3 swizzled dds

Featured Replies

  • Author
  • Localization

h3x3r, posted Mon Oct 31, 2022 5:19 pm (74043)


Hey there. I need to figure out which pixel format uses this dds. If anyone know, please shere info. Thanks! It's PS3 swizzled and dimension are 256x128
It should look like this:
Image
  • Author
  • Localization

spiritovod, posted Mon Oct 31, 2022 9:44 pm (74044)


It looks like there is only one channel in the file (or paletted image without palette), because data is not compressed and 256 * 128 = exactly file size (1 byte per pixel). You can decode it for example as r8_snorm swizzling in rawtex. It's not the original image, at least not without other supplementary data, like palette or something.
  • Author
  • Localization

h3x3r, posted Tue Nov 01, 2022 4:41 pm (74053)


Thanks spirit for clarify... So there's no other way how to de-swizzle data without using pixel format? That colored image is captured by ninja ripper and saved as DXT5 which coresponds to the size of swizzled dds.
  • Author
  • Localization

spiritovod, posted Tue Nov 01, 2022 6:32 pm (74054)


DXT5 is compressed format, where 4x4 block is encoded with 16 bytes, which corresponds to 1 byte per pixel as well, that's why the size is the same. But like it was already said above, the raw data you've provided looks more like non-compressed paletted image, so you need palette to reconstruct it - though in this case palette seems to be 16 colors only - unless the game is using shader-based coloring or something.
  • Author
  • Localization

h3x3r, posted Sat Dec 31, 2022 11:19 am (74819)


O.K figured it out. Thanks for hints spirit...
It was morton order i found that palette table which was in the texture file.

Noesis code:
Code:
  if rwTexPixelFormat == 11:
        untwid = bytearray()
        for x in range(rwTexWidth):
            for y in range(rwTexHeight):
                idx = noesis.morton2D(x, y)
                untwid = data[idx * 1:idx * 1 1]
        data = rapi.imageDecodeRawPal(untwid, bs.palette, rwTexWidth, rwTexHeight, 8, "b8 g8 r8 a8")
        texFmt = noesis.NOESISTEX_RGBA32


EDiT: Well seems like i am struggle with textures which don't have same width/height.
I solved textures with height power of two of width. But when it comes on power of four of width then i am lost.
This is code for height power of two of width. Means "width == height *2"
Code:
idx = noesis.morton2D(y, x)
rwUntwid = data[idx * 2:idx * 2 2]

I must also swap x,y.

But how to on "width == height *4"?

EDiT: Got it. With this function: data = rapi.imageFromMortonOrder
Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.