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

Moving green cursor with 's' hotkey does not update start position of annotation #398

Open
chrelli opened this issue May 3, 2019 · 2 comments

Comments

@chrelli
Copy link

chrelli commented May 3, 2019

The 'w' hotkey inserts an annotation between the green and red cursor, but only if the green cursor has been places by the mouse. If the green cursor has been moved to a new location by pressing the 's' hotkey, the annotation is still generated between the red cursor and the last position where the green cursor was placed by the mouse. Not where the green cursor is currently displayed.

When the 's' hotkey is pressed, the program should also internally update update the position of the green cursor.

It's a small bug, but it makes it impossible to annotate without using the mouse.

@chrelli
Copy link
Author

chrelli commented May 3, 2019

It looks like the start and stop times of annotations made by pressing 'w' is pulled here:

        public void NewAnnoKey()
        {
            if (IsDiscreteOrFree)
            {
                double start = MainHandler.Time.TimeFromPixel(MainHandler.Time.CurrentSelectPosition);
                double stop = MainHandler.Time.CurrentPlayPosition;

Instead of pulling the start time from the current select position, it should be pulled from the current position of the green cursor. Then both the start and stop times can be placed using the keyboard.

@chrelli
Copy link
Author

chrelli commented May 3, 2019

I noticed that the new annotation is made by converting the pixel value of the green cursor into time, which is not stable when the video is played back. If a new annotation is made with 'w' and playback is continued, pressing 's' does not always move the green cursor to the red cursor. Sometimes it chops off a bit of the newly made annotation (splitting) because the pixel is rounded to a different time value.

How about introducing a hotkey, which just does the simple task of setting the CurrentSelectedPosition be equal to the current playback position? It should be very easy to implement and would allow the start and end of annotations to be set w/o using the mouse..

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