Update \returns to the generic form

This commit is contained in:
Sylvain
2023-02-12 10:09:42 +01:00
committed by Sam Lantinga
parent 612584277c
commit 49e47b523a
14 changed files with 106 additions and 66 deletions

View File

@@ -214,8 +214,8 @@ extern DECLSPEC const char *SDLCALL SDL_GetRenderDriver(int index);
* SDL_CreateWindow())
* \param window a pointer filled with the window, or NULL on error
* \param renderer a pointer filled with the renderer, or NULL on error
* \returns 0 on success, or -1 on error; call SDL_GetError() for more
* information.
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*
@@ -567,7 +567,8 @@ extern DECLSPEC int SDLCALL SDL_GetTextureBlendMode(SDL_Texture *texture, SDL_Bl
*
* \param texture The texture to update.
* \param scaleMode the SDL_ScaleMode to use for texture scaling.
* \returns 0 on success, or -1 if the texture is not valid.
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*
@@ -580,7 +581,8 @@ extern DECLSPEC int SDLCALL SDL_SetTextureScaleMode(SDL_Texture *texture, SDL_Sc
*
* \param texture the texture to query.
* \param scaleMode a pointer filled in with the current scale mode.
* \returns 0 on success, or -1 if the texture is not valid.
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*
@@ -593,7 +595,8 @@ extern DECLSPEC int SDLCALL SDL_GetTextureScaleMode(SDL_Texture *texture, SDL_Sc
*
* \param texture the texture to update.
* \param userdata the pointer to associate with the texture.
* \returns 0 on success, or -1 if the texture is not valid.
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*
@@ -665,7 +668,7 @@ extern DECLSPEC int SDLCALL SDL_UpdateTexture(SDL_Texture *texture, const SDL_Re
* \param Vplane the raw pixel data for the V plane
* \param Vpitch the number of bytes between rows of pixel data for the V
* plane
* \returns 0 on success or -1 if the texture is not valid; call
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
@@ -694,7 +697,8 @@ extern DECLSPEC int SDLCALL SDL_UpdateYUVTexture(SDL_Texture *texture,
* \param UVplane the raw pixel data for the UV plane.
* \param UVpitch the number of bytes between rows of pixel data for the UV
* plane.
* \returns 0 on success, or -1 if the texture is not valid.
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*/
@@ -752,14 +756,14 @@ extern DECLSPEC int SDLCALL SDL_LockTexture(SDL_Texture *texture,
* The returned surface is freed internally after calling SDL_UnlockTexture()
* or SDL_DestroyTexture(). The caller should not free it.
*
* \param texture the texture to lock for access, which was created with
* \param texture the texture to lock for access, which must be created with
* `SDL_TEXTUREACCESS_STREAMING`
* \param rect a pointer to the rectangle to lock for access. If the rect is
* NULL, the entire texture will be locked
* \param surface this is filled in with an SDL surface representing the
* locked area
* \returns 0 on success, or -1 if the texture is not valid or was not created
* with `SDL_TEXTUREACCESS_STREAMING`
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*
@@ -1173,7 +1177,8 @@ extern DECLSPEC int SDLCALL SDL_RenderPoint(SDL_Renderer *renderer, float x, flo
* \param renderer The renderer which should draw multiple points.
* \param points The points to draw
* \param count The number of points to draw
* \returns 0 on success, or -1 on error
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*/
@@ -1200,7 +1205,8 @@ extern DECLSPEC int SDLCALL SDL_RenderLine(SDL_Renderer *renderer, float x1, flo
* \param renderer The renderer which should draw multiple lines.
* \param points The points along the lines
* \param count The number of points, drawing count-1 lines
* \returns 0 on success, or -1 on error
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*/
@@ -1225,7 +1231,8 @@ extern DECLSPEC int SDLCALL SDL_RenderRect(SDL_Renderer *renderer, const SDL_FRe
* \param renderer The renderer which should draw multiple rectangles.
* \param rects A pointer to an array of destination rectangles.
* \param count The number of rectangles.
* \returns 0 on success, or -1 on error
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*/
@@ -1251,7 +1258,8 @@ extern DECLSPEC int SDLCALL SDL_RenderFillRect(SDL_Renderer *renderer, const SDL
* \param renderer The renderer which should fill multiple rectangles.
* \param rects A pointer to an array of destination rectangles.
* \param count The number of rectangles.
* \returns 0 on success, or -1 on error
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*/
@@ -1290,7 +1298,8 @@ extern DECLSPEC int SDLCALL SDL_RenderTexture(SDL_Renderer *renderer, SDL_Textur
* around dstrect.w/2, dstrect.h/2).
* \param flip An SDL_RendererFlip value stating which flipping actions should
* be performed on the texture
* \returns 0 on success, or -1 on error
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*/
@@ -1342,7 +1351,8 @@ extern DECLSPEC int SDLCALL SDL_RenderGeometry(SDL_Renderer *renderer,
* if NULL all vertices will be rendered in sequential order.
* \param num_indices Number of indices.
* \param size_indices Index size: 1 (byte), 2 (short), 4 (int)
* \returns 0 on success, or -1 if the operation is not supported
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*
@@ -1517,7 +1527,7 @@ extern DECLSPEC int SDLCALL SDL_RenderFlush(SDL_Renderer *renderer);
* texture width or NULL if you don't need that value
* \param texh a pointer to a float value which will be filled with the
* texture height or NULL if you don't need that value
* \returns 0 on success, or -1 if the operation is not supported; call
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
@@ -1533,7 +1543,8 @@ extern DECLSPEC int SDLCALL SDL_GL_BindTexture(SDL_Texture *texture, float *texw
* See SDL_GL_BindTexture() for examples on how to use these functions
*
* \param texture the texture to unbind from the current OpenGL/ES/ES2 context
* \returns 0 on success, or -1 if the operation is not supported
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*
@@ -1584,7 +1595,8 @@ extern DECLSPEC void *SDLCALL SDL_GetRenderMetalCommandEncoder(SDL_Renderer *ren
*
* \param renderer The renderer to toggle
* \param vsync 1 for on, 0 for off. All other values are reserved
* \returns a 0 int on success, or non-zero on failure
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*/
@@ -1596,7 +1608,8 @@ extern DECLSPEC int SDLCALL SDL_SetRenderVSync(SDL_Renderer *renderer, int vsync
* \param renderer The renderer to toggle
* \param vsync an int filled with 1 for on, 0 for off. All other values are
* reserved
* \returns a 0 int on success, or non-zero on failure
* \returns 0 on success or a negative error code on failure; call
* SDL_GetError() for more information.
*
* \since This function is available since SDL 3.0.0.
*/