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
222c531b
Commit
222c531b
authored
Jan 10, 2007
by
Stefan Dösinger
Committed by
Alexandre Julliard
Jan 10, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Count the framerate per swapchain, not globally.
parent
9b492099
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
7 deletions
+7
-7
swapchain.c
dlls/wined3d/swapchain.c
+5
-7
wined3d_private.h
dlls/wined3d/wined3d_private.h
+2
-0
No files found.
dlls/wined3d/swapchain.c
View file @
222c531b
...
...
@@ -307,15 +307,13 @@ static HRESULT WINAPI IWineD3DSwapChainImpl_Present(IWineD3DSwapChain *iface, CO
/* FPS support */
if
(
TRACE_ON
(
fps
))
{
static
long
prev_time
,
frames
;
DWORD
time
=
GetTickCount
();
frames
++
;
This
->
frames
++
;
/* every 1.5 seconds */
if
(
time
-
prev_time
>
1500
)
{
TRACE_
(
fps
)(
"
@ approx %.2ffps
\n
"
,
1000
.
0
*
frames
/
(
time
-
prev_time
));
prev_time
=
time
;
frames
=
0
;
if
(
time
-
This
->
prev_time
>
1500
)
{
TRACE_
(
fps
)(
"
%p @ approx %.2ffps
\n
"
,
This
,
1000
.
0
*
This
->
frames
/
(
time
-
This
->
prev_time
));
This
->
prev_time
=
time
;
This
->
frames
=
0
;
}
}
...
...
dlls/wined3d/wined3d_private.h
View file @
222c531b
...
...
@@ -1313,6 +1313,8 @@ typedef struct IWineD3DSwapChainImpl
D3DPRESENT_PARAMETERS
presentParms
;
DWORD
orig_width
,
orig_height
;
long
prev_time
,
frames
;
/* Performance tracking */
/* TODO: move everything up to drawable off into a context manager
and store the 'data' in the contextManagerData interface.
IUnknown *contextManagerData;
...
...
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