Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
78cbe0bc
Commit
78cbe0bc
authored
Aug 28, 2011
by
Henri Verbeet
Committed by
Alexandre Julliard
Aug 29, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Rename WineD3DAdapterChangeGLRam() to adapter_adjust_memory().
And make it work on an adapter instead of a device.
parent
01d5a0f5
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
8 deletions
+7
-8
directx.c
dlls/wined3d/directx.c
+3
-5
resource.c
dlls/wined3d/resource.c
+2
-2
wined3d_private.h
dlls/wined3d/wined3d_private.h
+2
-1
No files found.
dlls/wined3d/directx.c
View file @
78cbe0bc
...
...
@@ -369,12 +369,10 @@ fail:
}
/* Adjust the amount of used texture memory */
unsigned
int
WineD3DAdapterChangeGLRam
(
struct
wined3d_device
*
device
,
int
glram
)
unsigned
int
adapter_adjust_memory
(
struct
wined3d_adapter
*
adapter
,
int
amount
)
{
struct
wined3d_adapter
*
adapter
=
device
->
adapter
;
adapter
->
UsedTextureRam
+=
glram
;
TRACE
(
"Adjusted gl ram by %d to %d
\n
"
,
glram
,
adapter
->
UsedTextureRam
);
adapter
->
UsedTextureRam
+=
amount
;
TRACE
(
"Adjusted adapter memory by %d to %d.
\n
"
,
amount
,
adapter
->
UsedTextureRam
);
return
adapter
->
UsedTextureRam
;
}
...
...
dlls/wined3d/resource.c
View file @
78cbe0bc
...
...
@@ -131,7 +131,7 @@ HRESULT resource_init(struct wined3d_resource *resource, struct wined3d_device *
HeapFree
(
GetProcessHeap
(),
0
,
resource
->
heapMemory
);
return
WINED3DERR_OUTOFVIDEOMEMORY
;
}
WineD3DAdapterChangeGLRam
(
device
,
size
);
adapter_adjust_memory
(
device
->
adapter
,
size
);
}
device_resource_add
(
device
,
resource
);
...
...
@@ -150,7 +150,7 @@ void resource_cleanup(struct wined3d_resource *resource)
if
(
resource
->
pool
==
WINED3DPOOL_DEFAULT
)
{
TRACE
(
"Decrementing device memory pool by %u.
\n
"
,
resource
->
size
);
WineD3DAdapterChangeGLRam
(
resource
->
device
,
0
-
resource
->
size
);
adapter_adjust_memory
(
resource
->
device
->
adapter
,
0
-
resource
->
size
);
}
LIST_FOR_EACH_SAFE
(
e1
,
e2
,
&
resource
->
privateData
)
...
...
dlls/wined3d/wined3d_private.h
View file @
78cbe0bc
...
...
@@ -1525,9 +1525,10 @@ struct wined3d_adapter
const
struct
blit_shader
*
blitter
;
};
unsigned
int
adapter_adjust_memory
(
struct
wined3d_adapter
*
adapter
,
int
amount
)
DECLSPEC_HIDDEN
;
BOOL
initPixelFormats
(
struct
wined3d_gl_info
*
gl_info
,
enum
wined3d_pci_vendor
vendor
)
DECLSPEC_HIDDEN
;
BOOL
initPixelFormatsNoGL
(
struct
wined3d_gl_info
*
gl_info
)
DECLSPEC_HIDDEN
;
extern
unsigned
int
WineD3DAdapterChangeGLRam
(
struct
wined3d_device
*
device
,
int
glram
)
DECLSPEC_HIDDEN
;
extern
void
add_gl_compat_wrappers
(
struct
wined3d_gl_info
*
gl_info
)
DECLSPEC_HIDDEN
;
/*****************************************************************************
...
...
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