Home | History | Annotate | Download | only in video

Lines Matching defs:overlay

38 	SDL_Overlay *overlay;
53 overlay = NULL;
57 overlay = video->CreateYUVOverlay(this, w, h, format, display);
59 /* If hardware YUV overlay failed ... */
60 if ( overlay == NULL ) {
61 overlay = SDL_CreateYUV_SW(this, w, h, format, display);
63 return overlay;
66 int SDL_LockYUVOverlay(SDL_Overlay *overlay)
68 if ( overlay == NULL ) {
69 SDL_SetError("Passed NULL overlay");
72 return overlay->hwfuncs->Lock(current_video, overlay);
75 void SDL_UnlockYUVOverlay(SDL_Overlay *overlay)
77 if ( overlay == NULL ) {
80 overlay->hwfuncs->Unlock(current_video, overlay);
83 int SDL_DisplayYUVOverlay(SDL_Overlay *overlay, SDL_Rect *dstrect)
89 if ( overlay == NULL || dstrect == NULL ) {
90 SDL_SetError("Passed NULL overlay or dstrect");
97 srcw = overlay->w;
98 srch = overlay->h;
104 srcw += (dstx * overlay->w) / dstrect->w;
106 srcx -= (dstx * overlay->w) / dstrect->w;
111 srcw -= (extra * overlay->w) / dstrect->w;
115 srch += (dsty * overlay->h) / dstrect->h;
117 srcy -= (dsty * overlay->h) / dstrect->h;
122 srch -= (extra * overlay->h) / dstrect->h;
138 return overlay->hwfuncs->Display(current_video, overlay, &src, &dst);
141 void SDL_FreeYUVOverlay(SDL_Overlay *overlay)
143 if ( overlay == NULL ) {
146 if ( overlay->hwfuncs ) {
147 overlay->hwfuncs->FreeHW(current_video, overlay);
149 SDL_free(overlay);