Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
04422cf3
Commit
04422cf3
authored
Dec 28, 1993
by
Guido van Rossum
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rot out all uses of time.milli*().
parent
b22d612e
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
6 deletions
+5
-6
Demo/sgi/video/Dsend.py
Demo/sgi/video/Dsend.py
+1
-1
Demo/sgi/video/VFile.py
Demo/sgi/video/VFile.py
+3
-4
Demo/sgi/video/Vsend.py
Demo/sgi/video/Vsend.py
+1
-1
No files found.
Demo/sgi/video/Dsend.py
View file @
04422cf3
...
@@ -156,7 +156,7 @@ def main():
...
@@ -156,7 +156,7 @@ def main():
rv
=
lvi
.
getnextpacket
()
rv
=
lvi
.
getnextpacket
()
if
not
rv
:
if
not
rv
:
time
.
millisleep
(
10
)
time
.
sleep
(
0.0
10
)
continue
continue
pos
,
data
=
rv
pos
,
data
=
rv
...
...
Demo/sgi/video/VFile.py
View file @
04422cf3
...
@@ -385,7 +385,6 @@ class Displayer(VideoParams):
...
@@ -385,7 +385,6 @@ class Displayer(VideoParams):
self
.
color0
=
None
# magic, used by clearto()
self
.
color0
=
None
# magic, used by clearto()
self
.
fixcolor0
=
0
# don't need to fix color0
self
.
fixcolor0
=
0
# don't need to fix color0
self
.
mustunpack
=
(
not
support_packed_pixels
())
self
.
mustunpack
=
(
not
support_packed_pixels
())
return
self
# setinfo() must reset some internal flags
# setinfo() must reset some internal flags
...
@@ -1184,11 +1183,11 @@ def test():
...
@@ -1184,11 +1183,11 @@ def test():
gl
.
prefsize
(
vin
.
getsize
())
gl
.
prefsize
(
vin
.
getsize
())
wid
=
gl
.
winopen
(
filename
)
wid
=
gl
.
winopen
(
filename
)
vin
.
initcolormap
()
vin
.
initcolormap
()
t0
=
time
.
millitimer
()
t0
=
time
.
time
()
while
1
:
while
1
:
try
:
t
,
data
,
cdata
=
vin
.
getnextframe
()
try
:
t
,
data
,
cdata
=
vin
.
getnextframe
()
except
EOFError
:
break
except
EOFError
:
break
dt
=
t0
+
t
-
time
.
millitimer
()
dt
=
t0
+
t
-
time
.
time
()
if
dt
>
0
:
time
.
millisleep
(
dt
)
if
dt
>
0
:
time
.
time
(
dt
)
vin
.
showframe
(
data
,
cdata
)
vin
.
showframe
(
data
,
cdata
)
time
.
sleep
(
2
)
time
.
sleep
(
2
)
Demo/sgi/video/Vsend.py
View file @
04422cf3
...
@@ -128,7 +128,7 @@ def main():
...
@@ -128,7 +128,7 @@ def main():
rv
=
lvi
.
getnextpacket
()
rv
=
lvi
.
getnextpacket
()
if
not
rv
:
if
not
rv
:
time
.
millisleep
(
10
)
time
.
sleep
(
0.0
10
)
continue
continue
pos
,
data
=
rv
pos
,
data
=
rv
...
...
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