Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-1.1
Commits
f0172537
Commit
f0172537
authored
Dec 13, 2009
by
Laurent Aimar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Implemented an fps(50) limiter in projectM.
parent
4308fd1d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
5 deletions
+9
-5
modules/visualization/projectm.cpp
modules/visualization/projectm.cpp
+9
-5
No files found.
modules/visualization/projectm.cpp
View file @
f0172537
...
...
@@ -24,6 +24,9 @@
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#ifndef __STDC_CONSTANT_MACROS
# define __STDC_CONSTANT_MACROS
#endif
#include <vlc_common.h>
#include <vlc_plugin.h>
...
...
@@ -318,6 +321,7 @@ static void *Thread( void *p_data )
int
i_last_height
=
0
;
for
(
;;
)
{
const
mtime_t
i_deadline
=
mdate
()
+
CLOCK_FREQ
/
50
;
/* 50 fps max */
/* Manage the events */
vout_ManageDisplay
(
p_sys
->
p_vd
,
true
);
if
(
p_sys
->
p_vd
->
cfg
->
display
.
width
!=
i_last_width
||
...
...
@@ -344,16 +348,16 @@ static void *Thread( void *p_data )
p_sys
->
p_projectm
->
renderFrame
();
/* */
vlc_restorecancel
(
cancel
);
mwait
(
i_deadline
);
cancel
=
vlc_savecancel
();
if
(
!
vout_opengl_Lock
(
gl
)
)
{
vout_opengl_Swap
(
gl
);
vout_opengl_Unlock
(
gl
);
}
/* TODO: use a fps limiter */
vlc_restorecancel
(
cancel
);
msleep
(
10000
);
cancel
=
vlc_savecancel
();
}
vlc_cleanup_pop
();
abort
();
...
...
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