How to change input data type SDL video display block (beaglebone) to uint4 from uint8
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
The SDL video display block has uint8 input data type and it has separate RGB components so this makes the final output to be 24 bit but I want to run a 16 bit interface display, so I'm getting a different output rather than the desired one on feeding the 24 bit data to the hdmi display. So how do I change the input data type to uint4 which will make to 12bit data of the SDL block
0 comentarios
Respuestas (1)
Walter Roberson
el 24 de Mzo. de 2018
The only support MATLAB has for uint4 is fread() and fwrite() which can unpack and pack bytes.
The fixed point toolbox can be used to define software mathematics with a 4 bit format, and could be used to pack three such values into a 12 bit format.
SDL has no support for 12 bit inputs. The closest it comes is support for 16 bit inputs and selecting subsets of the bits for rgb or RGBA components. SDL has no support for grayscale with more than 8 bits (and even then only through palette)
The Simulink SDL block for beaglebone has no support for anything other than uint8. The MATLAB SDL support for raspberry pi does not either.
There does appear to be a Mathworks .h for SDL that could perhaps be taken advantage of. I have not had a look at the interface it supports.
0 comentarios
Ver también
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!