chickadee » sdl2 » render-copy-ex!

render-copy-ex! renderer texture #!optional srcrect dstrect angle center flipprocedure

Copy all or part of the given texture onto the renderer, optionally rotating or flipping the texture. See SDL_RenderCopyEx. This procedure is available in sdl2 egg version 0.2.0 and higher.

  • renderer is the sdl2:renderer to copy the texture to.
  • texture is the source sdl2:texture.
  • srcrect is a sdl2:rect specifying the part of the texture to copy, or #f to copy the whole texture. It defaults to #f.
  • dstrect is a sdl2:rect specifying where on the renderer to copy the texture to, or #f to copy onto the entire renderer. It defaults to #f.
  • angle is a float specifying the angle in degrees to rotate the texture. It defaults to 0.
  • center is an sdl2:point specifying the center (pivot) of rotation, relative to the top left corner of dstrect, or #f to rotate around the center of dstrect. It defaults to #f.
  • flip is a list of zero, one, or two symbols indicating how to flip the texture. It defaults to '(), meaning no flipping. Supported symbols are:
    • 'horizontal = flip the texture horizontally
    • 'vertical = flip the texture vertically

Signals an exception of kind (exn sdl2) if an error occurs.