comparison include/SDL_video.h @ 296:fab1ddc4d7bf

Removed the API changes to preserve SDL 1.2 stability
author Sam Lantinga <slouken@libsdl.org>
date Wed, 06 Mar 2002 11:05:47 +0000
parents eadc0746dfaf
children f6ffac90895c
comparison
equal deleted inserted replaced
295:54ad1d2f1325 296:fab1ddc4d7bf
528 * 528 *
529 * SDL_LockSurface() returns 0, or -1 if the surface couldn't be locked. 529 * SDL_LockSurface() returns 0, or -1 if the surface couldn't be locked.
530 */ 530 */
531 extern DECLSPEC int SDL_LockSurface(SDL_Surface *surface); 531 extern DECLSPEC int SDL_LockSurface(SDL_Surface *surface);
532 extern DECLSPEC void SDL_UnlockSurface(SDL_Surface *surface); 532 extern DECLSPEC void SDL_UnlockSurface(SDL_Surface *surface);
533
534 /*
535 * SDL_LockRect() locks a portion of the surface designated by the 'rect'
536 * parameter, and saves the resulting pixels and pitch in the arguments.
537 * The rect will be clipped if it extends beyond the bounds of the surface
538 *
539 * This may be more efficient than a full lock if you are using a hardware
540 * surface and plan to make a few changes to small areas in the surface.
541 *
542 * While a rectangle is locked, no other lock or blit call may be called
543 * on the surface. No operating system or library calls should be made
544 * between lock/unlock pairs, as critical system locks may be held during
545 * this time.
546 *
547 * After the surface is unlocked, the pixels pointer is no longer valid.
548 *
549 * SDL_LockRect() returns 0, or -1 if the surface couldn't be locked.
550 */
551 extern DECLSPEC int SDL_LockRect(SDL_Surface *surface, SDL_Rect *rect, void **pixels, int *pitch);
552 extern DECLSPEC void SDL_UnlockRect(SDL_Surface *surface);
553 533
554 /* 534 /*
555 * Load a surface from a seekable SDL data source (memory or file.) 535 * Load a surface from a seekable SDL data source (memory or file.)
556 * If 'freesrc' is non-zero, the source will be closed after being read. 536 * If 'freesrc' is non-zero, the source will be closed after being read.
557 * Returns the new surface, or NULL if there was an error. 537 * Returns the new surface, or NULL if there was an error.