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
1407bd6b
Commit
1407bd6b
authored
Mar 27, 2009
by
Henri Verbeet
Committed by
Alexandre Julliard
Mar 27, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Create a separate function for setting basic format info.
parent
5a960ae8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
14 deletions
+7
-14
utils.c
dlls/wined3d/utils.c
+7
-14
No files found.
dlls/wined3d/utils.c
View file @
1407bd6b
...
...
@@ -375,7 +375,7 @@ static inline int getFmtIdx(WINED3DFORMAT fmt) {
return
-
1
;
}
BOOL
initPixelFormatsNoGL
(
WineD3D_GL_Info
*
gl_info
)
static
BOOL
init_format_base_info
(
WineD3D_GL_Info
*
gl_info
)
{
UINT
format_count
=
sizeof
(
formats
)
/
sizeof
(
*
formats
);
UINT
i
;
...
...
@@ -404,15 +404,18 @@ BOOL initPixelFormatsNoGL(WineD3D_GL_Info *gl_info)
return
TRUE
;
}
BOOL
initPixelFormatsNoGL
(
WineD3D_GL_Info
*
gl_info
)
{
return
init_format_base_info
(
gl_info
);
}
#define GLINFO_LOCATION (*gl_info)
BOOL
initPixelFormats
(
WineD3D_GL_Info
*
gl_info
)
{
unsigned
int
src
;
int
dst
;
gl_info
->
gl_formats
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
formats
)
/
sizeof
(
formats
[
0
])
*
sizeof
(
gl_info
->
gl_formats
[
0
]));
if
(
!
gl_info
->
gl_formats
)
return
FALSE
;
if
(
!
init_format_base_info
(
gl_info
))
return
FALSE
;
/* If a format depends on some extensions, remove them from the table above and initialize them
* after this loop
...
...
@@ -422,16 +425,6 @@ BOOL initPixelFormats(WineD3D_GL_Info *gl_info)
dst
=
getFmtIdx
(
gl_formats_template
[
src
].
fmt
);
desc
=
&
gl_info
->
gl_formats
[
dst
];
desc
->
format
=
formats
[
dst
].
format
;
desc
->
red_mask
=
formats
[
dst
].
redMask
;
desc
->
green_mask
=
formats
[
dst
].
greenMask
;
desc
->
blue_mask
=
formats
[
dst
].
blueMask
;
desc
->
alpha_mask
=
formats
[
dst
].
alphaMask
;
desc
->
byte_count
=
formats
[
dst
].
bpp
;
desc
->
depth_size
=
formats
[
dst
].
depthSize
;
desc
->
stencil_size
=
formats
[
dst
].
stencilSize
;
if
(
formats
[
dst
].
isFourcc
)
desc
->
Flags
|=
WINED3DFMT_FLAG_FOURCC
;
desc
->
glInternal
=
gl_formats_template
[
src
].
glInternal
;
desc
->
glGammaInternal
=
gl_formats_template
[
src
].
glGammaInternal
;
desc
->
glFormat
=
gl_formats_template
[
src
].
glFormat
;
...
...
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