Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
libSDL
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PocketInsanity
libSDL
Commits
99aee647
Commit
99aee647
authored
May 31, 2010
by
Sunny Sachanandani
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
X11_RenderPresent now uses XRender to blit back-buffers to the screen.
parent
6f98c350
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
0 deletions
+16
-0
SDL_x11render.c
src/video/x11/SDL_x11render.c
+16
-0
No files found.
src/video/x11/SDL_x11render.c
View file @
99aee647
...
@@ -1205,10 +1205,20 @@ X11_RenderPresent(SDL_Renderer * renderer)
...
@@ -1205,10 +1205,20 @@ X11_RenderPresent(SDL_Renderer * renderer)
if
(
!
(
renderer
->
info
.
flags
&
SDL_RENDERER_SINGLEBUFFER
))
{
if
(
!
(
renderer
->
info
.
flags
&
SDL_RENDERER_SINGLEBUFFER
))
{
for
(
dirty
=
data
->
dirty
.
list
;
dirty
;
dirty
=
dirty
->
next
)
{
for
(
dirty
=
data
->
dirty
.
list
;
dirty
;
dirty
=
dirty
->
next
)
{
const
SDL_Rect
*
rect
=
&
dirty
->
rect
;
const
SDL_Rect
*
rect
=
&
dirty
->
rect
;
#ifdef SDL_VIDEO_DRIVER_X11_XRENDER
if
(
data
->
xrender_available
==
SDL_TRUE
)
{
XRenderComposite
(
data
->
display
,
PictOpSrc
,
data
->
drawable_pict
,
None
,
data
->
xwindow_pict
,
rect
->
x
,
rect
->
y
,
0
,
0
,
rect
->
x
,
rect
->
y
,
rect
->
w
,
rect
->
h
);
}
else
#endif
{
XCopyArea
(
data
->
display
,
data
->
drawable
,
data
->
xwindow
,
XCopyArea
(
data
->
display
,
data
->
drawable
,
data
->
xwindow
,
data
->
gc
,
rect
->
x
,
rect
->
y
,
rect
->
w
,
rect
->
h
,
data
->
gc
,
rect
->
x
,
rect
->
y
,
rect
->
w
,
rect
->
h
,
rect
->
x
,
rect
->
y
);
rect
->
x
,
rect
->
y
);
}
}
}
SDL_ClearDirtyRects
(
&
data
->
dirty
);
SDL_ClearDirtyRects
(
&
data
->
dirty
);
}
}
XSync
(
data
->
display
,
False
);
XSync
(
data
->
display
,
False
);
...
@@ -1217,9 +1227,15 @@ X11_RenderPresent(SDL_Renderer * renderer)
...
@@ -1217,9 +1227,15 @@ X11_RenderPresent(SDL_Renderer * renderer)
if
(
renderer
->
info
.
flags
&
SDL_RENDERER_PRESENTFLIP2
)
{
if
(
renderer
->
info
.
flags
&
SDL_RENDERER_PRESENTFLIP2
)
{
data
->
current_pixmap
=
(
data
->
current_pixmap
+
1
)
%
2
;
data
->
current_pixmap
=
(
data
->
current_pixmap
+
1
)
%
2
;
data
->
drawable
=
data
->
pixmaps
[
data
->
current_pixmap
];
data
->
drawable
=
data
->
pixmaps
[
data
->
current_pixmap
];
#ifdef SDL_VIDEO_DRIVER_X11_XRENDER
data
->
drawable_pict
=
data
->
pixmap_picts
[
data
->
current_pixmap
];
#endif
}
else
if
(
renderer
->
info
.
flags
&
SDL_RENDERER_PRESENTFLIP3
)
{
}
else
if
(
renderer
->
info
.
flags
&
SDL_RENDERER_PRESENTFLIP3
)
{
data
->
current_pixmap
=
(
data
->
current_pixmap
+
1
)
%
3
;
data
->
current_pixmap
=
(
data
->
current_pixmap
+
1
)
%
3
;
data
->
drawable
=
data
->
pixmaps
[
data
->
current_pixmap
];
data
->
drawable
=
data
->
pixmaps
[
data
->
current_pixmap
];
#ifdef SDL_VIDEO_DRIVER_X11_XRENDER
data
->
drawable_pict
=
data
->
pixmap_picts
[
data
->
current_pixmap
];
#endif
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment