this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Updated renderer-demo to use the additional parameter for renderer->CopyImageFromSurface.

+6 -2
+6 -2
tests/renderer/main.c
··· 562 562 return 0; 563 563 } 564 564 565 - static GPU_Image* CopyImageFromSurface(GPU_Renderer* renderer, SDL_Surface* surface) 565 + static GPU_Image* CopyImageFromSurface(GPU_Renderer* renderer, SDL_Surface* surface, SDL_Rect* rect) 566 566 { 567 567 GPU_Log(" %s (dummy)\n", __func__); 568 568 569 569 if(surface == NULL) 570 570 return NULL; 571 571 572 - return renderer->impl->CreateImage(renderer, surface->w, surface->h, GPU_FORMAT_RGBA); 572 + int sw, sh; 573 + sw = rect == NULL ? surface->w : rect->w; 574 + sh = rect == NULL ? surface->h : rect->h; 575 + 576 + return renderer->impl->CreateImage(renderer, sw, sh, GPU_FORMAT_RGBA); 573 577 } 574 578 575 579