News:

--

Main Menu

marking the end of the video

Started by Papou, December 26, 2019, 09:44:31 PM

Previous topic - Next topic

Papou

Hi,

To make a selection in the video (clip), the A marker must be the first frame of it and the B marker the first frame not belonging to (following) it. And that is very well for programming purposes and consistence.
But that means that the end of the video cannot be selected. For example, if the selection is deleted between some A frame and B which is the last frame of the video, that leaves an extra frame at B dangling.
Also, jumping from key frame to key frame doesn't reach the end of the video.
Also, I'm sure that the source code contains subterfuges and unnecessary +1 or -1.
That has many practical inconveniences, but it's only a mere matter after considering the following.
The solution is a sort of Columbus egg: creating a dummy key frame after the end of the video.
It would display DUMMY END FRAME and some kind of this explanation.
Now one could select the end of the video and the subterfuges and +1 and -1 can go away.

It may seem weird, or even crazy.
But the more one thinks about it the more the conclusion is that it is the only correct solution.

eumagga0x2a

Which version of Avidemux do you refer to? My feeling is that all this is no more valid since 3 years of so.

Papou

It is not a question of version, it's a question of permanent logic.
One cannot select the last GOP if doing so needs to put the B marker after it and there's no frame to mark after it. A dummy frame is needed unless using some subterfuge that will be incorrect another way.

eumagga0x2a

#3
Quote from: Papou on December 27, 2019, 01:46:18 AM
One cannot select the last GOP if doing so needs to put the B marker after it

By default, the duration of the last frame is greater than zero and the B marker is placed at the end of the total video duration, i.e. after the last frame. To restore this placement of the B marker after it was moved elsewhere, navigate to marker A (with alternative keyboard shortcuts enabled, press "A"), reset marker (press "R") and set marker A to the current location (press "I"). That is all, no dummy frames needed.

If you build Avidemux from the current git master, you will notice, that the mp4 demuxer has been modified to give the last frame the same duration as the average frame increment, not just 1 ms.

Papou

#4
QuoteNo dummy frame needed
The least that can be said is that your explanation is confusing compared to the clarity of the explicitly apparent dummy frame.
I made a one frame video and the times displayed after loading are 00.000/00.033.
Also, the B marker is set at 00.033
All that as you said so far.
Except that 00.033 B is the dummy frame but that it is not apparent at all.
Now I set B elsewhere but no "navigate to marker A, (press "R") (press "I")" or else got it back (which is what should normally be done without kludge before saving every complete video).
Also, pulling the cursor to the extreme right produced no time nor image change whether with my scheme it would reach the dummy frame 00.033 and display a dummy text and allow simply clicking "set B".
Also, I saved the video with A=B=0 and it did save the one frame, which is incorrect: it should have at least warned that the video selection is empty.
Avidemux uses undocumented, unapparent kludges.
All in all, my dummy frame proposition is replacing a world of complex confusion with crystal clarity.
P.S. by "dummy frame" I do not mean a real one, of course, just the program behaving as if there was one.

AQUAR

I remember the OP raising this same topic many years ago.
It didn't attract any responses or patches for perceived kludges.






eumagga0x2a

Quote from: Papou on January 01, 2020, 04:11:14 AM
Also, pulling the cursor to the extreme right produced no time nor image change

Dragging the navigation slider seeks to keyframes only. To seek to the last frame of video, press "E" when using alternative keyboard shortcuts.

QuoteAlso, I saved the video with A=B=0 and it did save the one frame, which is incorrect: it should have at least warned that the video selection is empty.

I acknowledge this minor inconsistence.

Quote from: AQUAR on January 01, 2020, 12:06:49 PM
I remember the OP raising this same topic many years ago.

The behavior of Avidemux regarding the last frame of video was changed about 3 years ago. I don't feel that any further changes are really necessary.

Papou

eumagga0x2a I much appreciate what you're doing.
What I try to suggest is easy changes with great effect.

This is simply amazing !!!
I was requesting that the video displayed a dummy frame as the last frame.
And that's the way it is!!!
And the requester did not notice !!!

That's simply because that dummy frame contains some image of the video.
And it seems it is part of the video.
And the unaware user will madly try to remove it in vain

That frame should display some text like:

Avidemux Video End
This dummy frame is not part of the video.
It is where the B Marker must be set as part of selecting the end of the video.

Also, in the Go menu, "End" should be labeled "End of video", not "last fame".