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

Implement dithering #2

Open
jserv opened this issue Aug 9, 2022 · 2 comments
Open

Implement dithering #2

jserv opened this issue Aug 9, 2022 · 2 comments
Assignees

Comments

@jserv
Copy link

jserv commented Aug 9, 2022

Dithering is an intentionally applied form of noise used to randomize quantization error, preventing large-scale patterns such as color banding in images.
Prior art:

The upstream work was landed in tyrquake.

@alanjian85
Copy link
Collaborator

I'm not sure what dithering algorithm tyrquake uses, but the bit depth of the texture source, pbase, and the corresponding output pixel location, pdest, are both 256 colors, so they don't appear to have anything to do with error diffusion and quantization error randomization because the error of colors is negligible. Furthermore, despite the fact that static data used in the process is called dither_kernel, it doesn't use a conventional method of image convolution, so additional diagnostics may be required. I adapted it for the quake-embedded, though, so if it's still required, I can provide it.

@jserv
Copy link
Author

jserv commented Aug 21, 2022

Furthermore, despite the fact that static data used in the process is called dither_kernel, it doesn't use a conventional method of image convolution, so additional diagnostics may be required. I adapted it for the quake-embedded, though, so if it's still required, I can provide it.

My intention was to provide a runtime switch to bring visual computing "overheads," so that rv32emu users can be aware of the impacts, especially when JIT compilation is ready for performance boost. Dithering might be a good fit for this purpose. Feel free to propose another approach as a runtime switch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants