|
OldSchool Library 1.6.0
|
Macros | |
| #define | oslDrawImageXY(img, px, py) ({ (img)->x = (px), (img)->y = (py); oslDrawImage(img); }) |
| Draws an image at the specified position. | |
| #define | oslDrawImageSimpleXY(img, px, py) ({ (img)->x = (px), (img)->y = (py); oslDrawImageSimple(img); }) |
| Draws an image at the specified position (backward compatibility). | |
Functions | |
| void | oslDrawImage (OSL_IMAGE *img) |
| Draws an image at its current position. | |
| void | oslDrawImageSimple (OSL_IMAGE *img) |
| Draws an image at its current position (deprecated). | |
| void | oslDrawImageBig (OSL_IMAGE *img) |
| Draws a very large image. | |
Image support in OSLib.
| #define oslDrawImageXY | ( | img, | |
| px, | |||
| py | |||
| ) | ({ (img)->x = (px), (img)->y = (py); oslDrawImage(img); }) |
Draws an image at the specified position.
This macro sets the position of the image img to the coordinates (px, py) and then draws it using the oslDrawImage function.
| img | Pointer to the image to be drawn. |
| px | The x-coordinate where the image should be drawn. |
| py | The y-coordinate where the image should be drawn. |
oslDrawImage to render the image. | #define oslDrawImageSimpleXY | ( | img, | |
| px, | |||
| py | |||
| ) | ({ (img)->x = (px), (img)->y = (py); oslDrawImageSimple(img); }) |
Draws an image at the specified position (backward compatibility).
This macro is similar to oslDrawImageXY, but uses the oslDrawImageSimple function for drawing. It is kept for backward compatibility and is not recommended for new code.
| img | Pointer to the image to be drawn. |
| px | The x-coordinate where the image should be drawn. |
| py | The y-coordinate where the image should be drawn. |
oslDrawImageSimple, which is kept for compatibility but should be avoided in new code.
|
extern |
Draws an image at its current position.
This function renders the image specified by the img parameter at the position stored in the image's x and y attributes. The image must be properly initialized and loaded before calling this function.
| img | Pointer to the OSL_IMAGE structure representing the image to be drawn. |
x and y attributes, which should be set before drawing.
|
extern |
Draws an image at its current position (deprecated).
This function renders the image specified by the img parameter at the position stored in the image's x and y attributes. It is provided for backward compatibility with older code but should not be used in new code.
| img | Pointer to the OSL_IMAGE structure representing the image to be drawn. |
oslDrawImage instead.
|
extern |
Draws a very large image.
This function is designed to draw images larger than the 512 texels the GE samples per axis. It renders images up to 1024 pixels in width (wider ones come out wrong), but comes with additional complexity and potentially significant performance drawbacks.
Texture wrapping (oslSetTextureWrap) is not supported. Make sure that offset coordinates are within the bounds of the image to avoid unpredictable results.
| img | Pointer to the OSL_IMAGE structure representing the image to be drawn. |
Use oslDrawImage for images up to 512x512 pixels: this function falls back to it for them.