-
Notifications
You must be signed in to change notification settings - Fork 334
Add video panning #207
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
base: master
Are you sure you want to change the base?
Add video panning #207
Conversation
Crosshair drawing is broken when videoAr != displayAr
I'm not sure about that scale_factor, i don't know how to test that
We now kinda have proper video panning, lol.
I solved a couple of years ago. I think it's more perfect that way. https://drive.google.com/file/d/150QXmgTLgTmVBdu0Zbo_3CLPttpbwGMz/view?usp=sharing |
@megax Yeah that looks good, i was also considering stopping the zoom from changing the preview window size, but haven't got around to it yet (and i don't feel like i'm being pressured, looking at the state of the project). I tried searching for this feature a while ago, found nothing just github issues with 0 progress on them, so I considered it non-existent. Is it Haru-Subs private :D ? If not, create a PR please. |
@moex3 Yeah sorry, the code is private. I exclusively developed it for our group in 2018 and our group and it stays exclusive for the time being. I just sent the video, so you can take a look at what it "should" look like. Our Aegi contains quite a few more features besides this, so it's not a little project. These mechanics took a lot of time to figure out. Sorry for getting you excited, but I really can't publicize it, since it belongs to our team(now Guddo-FanSub). |
with a "good enough" implementation
The preview window would change in width, when the video was being zoomed. Possibly, because on windows, zooming only calls UpdateSize once, but on linux, it gets called multiple, like 8 times. Rounding fixed it.
Some updates! Now the video can be zoomed without affecting the displaying window size. Scrollwheel zooms the video, and ctrl+scrollwheel zooms the entire preview window. Zooming centers around the cursor. Zooming now feels more linear, but don't zoom too much, it gets weird. Also, this implementation of it is not perfect, as after a zoom-in, a zoom-out does not result in the original video size. Zoom-zoom. Preview: prev2.mp4 |
@moex3
|
I'm not entirely sure, that this is how it's supposed to be added. This requires editing the already existing hotkey.json file (shows path in log, if it exists). Should this also be added to hotkey.cpp?
Hi! @moex3 ,thanks for this beautiful useful feature, but i don't know how to install it in my aegisub, can you help me please. |
Hi @seiya-eyth! You can use AegisubDC, which is a fork of aegisub that has this PR merged. |
We now kinda have proper video panning, lol.
This reverts commit 3d525d9. The default hotkey is not required. People can just add a custom one from the hotkey settings if they want this.
@moex3 it worked and i can zoom now. But the json and cpp files, where i have to paste them ? |
@seiya-eyth Those files are only needed if you want to build aegisub from source code. AegisubDC provides already built exe files, so if you downloaded that, and it works, then it's fine. You have nothing else to do. The json file was used to set a hotkey to reset the video zoom. You can set a custom one for it in the settings if you want that. |
Add the ability to move the preview video around, and add a menu item to reset the panning.
It's a little bit hacky, as i got this to work by trial and error.
I tested it on windows with the wangqr fork (as i was able to build that), and on linux with xorg. Both works fine, however on wayland the zoom anchor seems to be in the bottom left corner instead of the upper left one and that breaks the mouse position. But this requires more testing.
It can be used by dragging, with the middle mouse button.
Example
closes #187, closes #107