Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
03c6a0d9
Commit
03c6a0d9
authored
May 11, 2009
by
Roderick Colenbrander
Committed by
Alexandre Julliard
May 12, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
opengl32: Add a wglShareLists test.
parent
db0bd528
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
54 additions
and
0 deletions
+54
-0
opengl.c
dlls/opengl32/tests/opengl.c
+54
-0
No files found.
dlls/opengl32/tests/opengl.c
View file @
03c6a0d9
...
...
@@ -285,6 +285,59 @@ static void test_setpixelformat(HDC winhdc)
}
}
static
void
test_sharelists
(
HDC
winhdc
)
{
HGLRC
hglrc1
,
hglrc2
,
hglrc3
;
int
res
;
hglrc1
=
wglCreateContext
(
winhdc
);
res
=
wglShareLists
(
0
,
0
);
ok
(
res
==
FALSE
,
"Sharing display lists for no contexts passed!
\n
"
);
/* Test 1: Create a context and just share lists without doing anything special */
hglrc2
=
wglCreateContext
(
winhdc
);
if
(
hglrc2
)
{
res
=
wglShareLists
(
hglrc1
,
hglrc2
);
ok
(
res
,
"Sharing of display lists failed
\n
"
);
wglDeleteContext
(
hglrc2
);
}
/* Test 2: Share display lists with a 'destination' context which has been made current */
hglrc2
=
wglCreateContext
(
winhdc
);
if
(
hglrc2
)
{
res
=
wglMakeCurrent
(
winhdc
,
hglrc2
);
ok
(
res
,
"Make current failed
\n
"
);
res
=
wglShareLists
(
hglrc1
,
hglrc2
);
todo_wine
ok
(
res
,
"Sharing display lists with a destination context which has been made current passed
\n
"
);
wglMakeCurrent
(
0
,
0
);
wglDeleteContext
(
hglrc2
);
}
/* Test 3: Share display lists with a context which already shares display lists with another context.
* According to MSDN the second paramater can't share any display lists but some buggy drivers might allow it */
hglrc3
=
wglCreateContext
(
winhdc
);
if
(
hglrc3
)
{
res
=
wglShareLists
(
hglrc3
,
hglrc1
);
ok
(
res
==
FALSE
,
"Sharing of display lists failed for a context which already shared lists before
\n
"
);
wglDeleteContext
(
hglrc3
);
}
/* Test 4: Share display lists with a 'source' context which has been made current */
hglrc2
=
wglCreateContext
(
winhdc
);
if
(
hglrc2
)
{
res
=
wglMakeCurrent
(
winhdc
,
hglrc1
);
ok
(
res
,
"Make current failed
\n
"
);
res
=
wglShareLists
(
hglrc1
,
hglrc2
);
ok
(
res
,
"Sharing display lists with a source context which has been made current passed
\n
"
);
wglMakeCurrent
(
0
,
0
);
wglDeleteContext
(
hglrc2
);
}
}
static
void
test_makecurrent
(
HDC
winhdc
)
{
BOOL
ret
;
...
...
@@ -601,6 +654,7 @@ START_TEST(opengl)
test_makecurrent
(
hdc
);
test_setpixelformat
(
hdc
);
test_sharelists
(
hdc
);
test_colorbits
(
hdc
);
test_gdi_dbuf
(
hdc
);
...
...
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