Skip to content

Send time of point within stroke. #5

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion parsestf.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,7 @@ def parse(self):

xa=0
ya=0
sample_in_stroke = 0
while True:
header = self.get_header()
if header==0 or header==1:
Expand All @@ -213,6 +214,8 @@ def parse(self):
if time==0:
self.handle_stroke_end(time)
break
sample_in_stroke += time
point_time = start_time + sample_in_stroke * 1000 // self.speed

do_delta = True
if header > 0:
Expand Down Expand Up @@ -244,7 +247,7 @@ def parse(self):
ya *= 256 / time
f0 += deltaf

self.handle_point(x0, y0, f0, start_time)
self.handle_point(x0, y0, f0, point_time)
pass
except Exception, e:
print e
Expand Down