Forum

Can't apply blur effect after ImagePlayer (Stride) using DDS image sequence

Hello,

I’m trying to apply some blur effect to an image sequence in Stride.
In my current project, I’m using a DDS image sequence, and so the ImagePlayer (Stride) which outputs a texture each frame.
But when trying to blur it, then it outputs a null texture.
If I isolate one frame from that DDS image sequence using a FileTexture, then it works.

If I use a PNG image sequence, instead of the DDS one, then it works.

Any hint on how to solve this?
Thank you!

I suppose the dds images don’t have mips and somehow Blur can’t handle mipmap generation for BC7. Have you enabled Pause on Error and Jump to Error in your settings? If not, do that to see what the exact error is.
FileTexture does generate mipmaps per default, ImagePlayer doesn’t. Resize your ouput IO-Boxes so you can completely see the info text.
If I am correct you can either generate your BC7 sequence with mips (might increase compression/loading time, filesize and ram usage). Or (as a workaround) use something like ChangeFormat in between ImagePlayer and Blur.

You’re right, my DDS images don’t have any mips.
I didn’t know about that and the mipmap generation with Blur.
And yes, I enabled those two settings, but the error message : ‘The parameter is incorrect’ is a bit vague.

So to follow what you said, I’ve generated new DDS images with mips this time.
It turns out that by using BC7 format, even with mips, Blur throws the same error (and so a null texture).
But if I’m using R8G8B8A8 format with mips, then Blur works.

If I use ChangeFormat (which I didn’t know about, so thank you for this!), it also works but you can see some artifacts in the output texture compare to the DDS directly generated in R8G8B8A8 format + Blur.
I also tried to change the format from BC7 to BC7 (just out of curiosity), and then it throws the same error but outputs an alpha texture in R8G8B8A8 format.

Did you try GaussianBlur? it doesn’t rely on mipmaps… But you might need ChangeFormat to decompress the pixels before it.

It’s not the mips but the bc7 format, didn’t encouter that before …
This works:

1 Like

Yes it seems it’s coming from the BC7 format.

Thanks for the hint with the SRgbToLinear!
And yes, I realized (and it’s confirmed with you screenshot) that I used ChangeFormat to R8G8B8A8_Unorm instead of R8G8B8A8_Unorm_SRgb.
Using the later + Blur removes the artifacts I was mentioning.

Thanks!

image

This conversion is valid and should not change the colors, of course… it seems to be a bug. I’ll look into it.

2 Likes