Skip to content
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

Repopulating Signatures: Some Questions and an Implementation #24

Open
MosheBerman opened this issue Aug 24, 2016 · 0 comments
Open

Repopulating Signatures: Some Questions and an Implementation #24

MosheBerman opened this issue Aug 24, 2016 · 0 comments

Comments

@MosheBerman
Copy link

MosheBerman commented Aug 24, 2016

Hey Jason,

Thanks for a cool library. It works really well!

I've been using this library in an app at work. We decided that we need to re-populate the screen with a previously captured signature in some use cases. (Say the user signs, but isn't ready to save, but they need to look at some other view controller in the middle of their workflow.)

I got it working, but before setting up a pull request, there are a couple of things I wanted to address.

I tried collecting the vertices as they were generated and then passing them back to addVertex() but the call to glMapBufferOES fails and the log spews a bunch of messages: "Attempting to copy gl buffer prematurely." Since that didn't work, I tried something else.

I added my own target to the pan and tap gesture recognizers and recorded the gesture locations and velocities in their respective views. When the signature view comes back on screen, I play back the gestures and the signature draws appropriately.

Is there a better way to redraw the vertices without mocking the gestures? I'm not so familiar with OpenGL ES, so I might have been missing some setup in my initial implementation.

Also, because my signature view is in a scroll view which jumps when the signature finishes (as a result of some of application logic - it's collecting data then refreshing the screen) there's a streak of "ink" towards the top of the signature view.

One last thing - I'd love to contribute this back to the project (if it's wanted) but I need to clear it with my company for legal reasons. I don't know if they consider the gesture recording/playback mechanism to be their IP. In the meantime, more context on the GL question might help someone else even if I can't.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant