|
Size: 914
Comment: add code example from SDL_GetVersion as Include
|
Size: 945
Comment: change include to work w/ comment
|
| Deletions are marked like this. | Additions are marked like this. |
| Line 3: | Line 3: |
| ||<tablewidth="100%" style="color: #FF0000;" :> DRAFT|| | ||<tablewidth="100%"style="color: rgb(255, 0, 0); text-align: center;">DRAFT || |
| Line 11: | Line 12: |
| ||Uint8||'''major'''||major version|| ||Uint8||'''minor'''||minor version|| ||Uint8||'''patch'''||update version|| |
||Uint8 ||'''major''' ||major version || ||Uint8 ||'''minor''' ||minor version || ||Uint8 ||'''patch''' ||update version || |
| Line 16: | Line 18: |
| <<Include(SDL_GetVersion, , , from="== Code Examples ==", to="== Remarks ==")>> | <<Include(SDL_GetVersion, , , from="== Code Examples ==", to="## End 1")>> |
| Line 21: | Line 23: |
| == Remarks == Represents the library's version as three levels: |
|
| Line 22: | Line 26: |
| == Remarks == Represents the library's version as three levels: *major revision (increments with massive changes, additions, and enhancements) *minor revision (increments with backwards-compatible changes to the major revision), and *patchlevel (increments with fixes to the minor revision) |
* major revision (increments with massive changes, additions, and enhancements) * minor revision (increments with backwards-compatible changes to the major revision), and * patchlevel (increments with fixes to the minor revision) |
| Line 29: | Line 31: |
| .[[SDL_GetVersion]] | . [[SDL_GetVersion]] |
| Line 32: | Line 34: |
| [[CategoryStruct]] | CategoryStruct |
DRAFT |
SDL_version
A structure that contains information about the version of SDL in use.
Contents
Data Fields
Uint8 |
major |
major version |
Uint8 |
minor |
minor version |
Uint8 |
patch |
update version |
Code Examples
Include: Nothing found for "## End 1"!
SDL_version compiled;
SDL_version linked;
SDL_VERSION(&compiled);
SDL_GetVersion(&linked);
printf("We compiled against SDL version %d.%d.%d ...\n",
compiled.major, compiled.minor, compiled.patch);
printf("But we are linking against SDL version %d.%d.%d.\n",
linked.major, linked.minor, linked.patch);
Remarks
If you are linking to SDL dynamically, then it is possible that the current version will be different than the version you compiled against. This function returns the current version, while SDL_VERSION() is a macro that tells you what version you compiled with.
This function may be called safely at any time, even before SDL_Init().
Related Macros
Related Functions
You can add your code example here
Remarks
Represents the library's version as three levels:
- major revision (increments with massive changes, additions, and enhancements)
- minor revision (increments with backwards-compatible changes to the major revision), and
- patchlevel (increments with fixes to the minor revision)
