DX11 PixelData(2D) and AsTexture(2D Raw) not working for me

I am trying to use DX11 PixelData and AsTexture to send images over the net. First I was unable to get AsTexture to work, and in trying to debug it found that PixelData does not work properly with a texture from FileTexture(2D), only from a Renderer.

If the input to PixelData is from FileTexture, it outputs Valid as True, and the right number of Raw bytes, but they are all zeros. When fed from the output of a Renderer (TempTarget), the data is correct.

AsTexture never works, even when Format is fed into it from an Info node of the texture going into PixelData. I can see the output of PixelData is correct, as I can feed the Raw data into AsValue, divide it by 256, and feed that into DynamicTexture and get the original texture back.

Am I missing something here? Does AsTexture just not work with larger sizes than the trivial examples in the help patch? Thanks!

This is happening with 35.8_x64 and 38.1_x64, DX11 1.3.1, on Win10 x64 Enterprise 1809, one system with GTX 1080s and one with GTX 2070s.

PixelDataBug.v4p (18.7 KB)

Last time i needed that i used a bit other tech, there is function in C# something like “texture from stream” (i think it used in file loader) so basically it dosen’t care about any thing like size or format… (6.1 KB)

sadly i can’t find source of it…

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.