Yeesum Chan
Yeesum Chan

Reputation: 27

Fill_Rect in SDL

I got some question for SDL_FillRect.

normally the function work like that: SDL_FillRect(screen, &screen->clip_rect, color);

My question is, instead of passing a single color, can I fill up my Rect with multiple color which contain different Red, blue, and green channel of pixel?

Upvotes: 0

Views: 367

Answers (1)

TheBuzzSaw
TheBuzzSaw

Reputation: 8836

How would you go about determining the color pattern? I think the closest you are gonna get is with SDL_BlitSurface. Pattern a surface and then blit it onto another surface.

http://www.libsdl.org/docs/html/sdlblitsurface.html

Upvotes: 2

Related Questions