DevIL Documentation Home | Previous | Next

ilOverlayImage

The ilOverlayImage function overlays an image onto the current image.


ILboolean ilOverlayImage(
  ILuint Src,
  ILint XCoord,
  ILint YCoord,
  ILint ZCoord
);

Parameters

Src
The image to copy.
XCoord
The starting x position of the current image to copy Src to.
YCoord
The starting y position of the current image to copy Src to.
ZCoord
The starting z position of the current image to copy Src to.

Remarks

The ilOverlayImage function copies the image named by Src onto the current bound image. XCoord, YCoord and ZCoord are allowed to be any number, even negative numbers, for if you want to start copying Src in the middle of it to the current image's left side. If the image named by Src has alpha components, then blending will occur, instead of just a simple overlay.

Error Codes

IL_ILLEGAL_OPERATION - There is currently no image bound. Use ilGenImages and ilBindImage before calling this function. Another possible source of this error is that Src was an invalid image id.

See Also

ilGenImages, ilBindImage