Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dumping binary context of 2D array texture only works for selected layer. #3149

Closed
reduz opened this issue Nov 26, 2023 · 1 comment
Closed
Labels
Bug A crash, misbehaviour, or other problem Unresolved Waiting for a fix or implementation

Comments

@reduz
Copy link

reduz commented Nov 26, 2023

Description

Inspecting an array texture as binary and saving it to a file only saves one layer of the whole texture.

Steps to reproduce

When inspecting an array texture as binary:

image

This has 24 layers, hence the total size should be 686128*24 = 7990272

Exploring as binary shows the whole thing:
image
image

But RMB -> Export to Bytes

Only saves one layer:
332928 save_data.bin

7990272 / 24 = 332928

Either the whole texture should be saved, or an option to save either the whole texture or the current layers should be offered.

I found this error while trying to workaround #3148, by the way.

Environment

  • RenderDoc version: 1.28
  • Operating System: Ubuntu
  • Graphics API: Vulkan
  • GPU: GTX 1650
@baldurk baldurk added Bug A crash, misbehaviour, or other problem Unresolved Waiting for a fix or implementation labels Nov 27, 2023
@baldurk baldurk closed this as completed in 92e0fab Dec 5, 2023
@baldurk
Copy link
Owner

baldurk commented Dec 5, 2023

When viewing a texture's bytes in the buffer viewer it is intentional that only one subresource is displayed at a time, since the physical layout of subresources is not necessarily defined or consistent. That commit clarifies this (and disables the byte offset/length fields as those are not supported for textures).

If you want to save the whole texture to a file without conversion, you can save to dds which supports all texture formats natively and has a defined layout. You could also use a python extension to save to a custom format if you want the raw bits with no headers and custom alignment/ordering.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug A crash, misbehaviour, or other problem Unresolved Waiting for a fix or implementation
Projects
None yet
Development

No branches or pull requests

2 participants