Clean up some warnings
This commit is contained in:
parent
eb394ac0af
commit
e795692614
8 changed files with 27 additions and 20 deletions
|
@ -224,8 +224,8 @@ void GraphicsFramebufferWidget::OnUpdate()
|
|||
{
|
||||
QImage decoded_image(framebuffer_width, framebuffer_height, QImage::Format_ARGB32);
|
||||
u32* color_buffer = (u32*)Memory::GetPointer(framebuffer_address);
|
||||
for (int y = 0; y < framebuffer_height; ++y) {
|
||||
for (int x = 0; x < framebuffer_width; ++x) {
|
||||
for (unsigned y = 0; y < framebuffer_height; ++y) {
|
||||
for (unsigned x = 0; x < framebuffer_width; ++x) {
|
||||
u32 value = *(color_buffer + x + y * framebuffer_width);
|
||||
|
||||
decoded_image.setPixel(x, y, qRgba((value >> 16) & 0xFF, (value >> 8) & 0xFF, value & 0xFF, 255/*value >> 24*/));
|
||||
|
@ -239,8 +239,8 @@ void GraphicsFramebufferWidget::OnUpdate()
|
|||
{
|
||||
QImage decoded_image(framebuffer_width, framebuffer_height, QImage::Format_ARGB32);
|
||||
u8* color_buffer = Memory::GetPointer(framebuffer_address);
|
||||
for (int y = 0; y < framebuffer_height; ++y) {
|
||||
for (int x = 0; x < framebuffer_width; ++x) {
|
||||
for (unsigned y = 0; y < framebuffer_height; ++y) {
|
||||
for (unsigned x = 0; x < framebuffer_width; ++x) {
|
||||
u8* pixel_pointer = color_buffer + x * 3 + y * 3 * framebuffer_width;
|
||||
|
||||
decoded_image.setPixel(x, y, qRgba(pixel_pointer[0], pixel_pointer[1], pixel_pointer[2], 255/*value >> 24*/));
|
||||
|
@ -254,8 +254,8 @@ void GraphicsFramebufferWidget::OnUpdate()
|
|||
{
|
||||
QImage decoded_image(framebuffer_width, framebuffer_height, QImage::Format_ARGB32);
|
||||
u32* color_buffer = (u32*)Memory::GetPointer(framebuffer_address);
|
||||
for (int y = 0; y < framebuffer_height; ++y) {
|
||||
for (int x = 0; x < framebuffer_width; ++x) {
|
||||
for (unsigned y = 0; y < framebuffer_height; ++y) {
|
||||
for (unsigned x = 0; x < framebuffer_width; ++x) {
|
||||
u16 value = *(u16*)(((u8*)color_buffer) + x * 2 + y * framebuffer_width * 2);
|
||||
u8 r = (value >> 11) & 0x1F;
|
||||
u8 g = (value >> 6) & 0x1F;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue