Closed masc4ii closed 6 years ago
'Could' is the wrong word - 'Should' is the correct one :D
I worked on this old enhancement issue now. What is working now:
What has to be done: -> Cut export. For the video frames this should be no problem. But for audio this is a bit more difficult, at least for me..., cut out is no problem, but I don't know the syntax for a cut in. I get only crashes. Could someone please assist here?
Theoretically cutting the beginning is as simple as cutting the end. Where exactly are you stuck?
My problem was to cut the beginning in audio_mlv.c line 132. The end works simply with the 2nd parameter. For the first I wanted to increment the starting address, but I got only crashes.
This function also needs 2 parameters then - in and out frame.
Video export is cut now too. :-)
Clip loops from cut in to cut out when looping enabled. Is that intended behavior?
Yes it is. And it was not that easy as it looks ;-) And not only the loops should be cutted: playback should stop at cut out, if loop is disabled. If you press the first frame button, the position goes to cut in. If you press again, it jumps to frame 1.
Okay. I got it. Feature complete for cutIn cutOut. @ilia3101 : I made a new audio write wave function for compatibility reasons to your code. If you like you could easily adapt to the parameters of the new function: cut_in = 1, cut_out = getMlvFrames(video). Then we could delete the old one (and name the new again as the old function). @ all: please test, I expect some bugs. The change was more work as expected...
@ilia3101 : now I think you mustn't change it anymore. I made a function which generates the audio header, so the write wave functions are way smaller. So we can have both version in the code...
Works fine here for cutting video (have no audio, so I cannot tell anything about audio). Thanks for implementing.
Great job! :)
Thank you. So we can close, when it works for you?
I corrected buffer pointer + in_offset issue. Now everything is right and synced.
Cool, thank you. So this was not working on Linux? Haven't had a problem on Mac... but now it is save... :-)
I can't believe this was not a problem on mac really ;). It should be a problem anywhere!
fwrite been starting saving the data from buffer 'pointer + *cut_in 2**'!
If it is the case I'm happy that I'm not developing on a Mac! :P, I don't even understand what mechanism corrects this on the mac!
btw you wrote this some while ago:
My problem was to cut the beginning in audio_mlv.c line 132. The end works simply with the 2nd parameter. For the first I wanted to increment the starting address, but I got only crashes.
How did you solve this problem? I can't find the related commit.
I solved it as you can see. Before the syntax was completely wrong :-D
ok, never mind :)
I'm just so curious how compiler? or anything corrects incorrect memory access for mac. As you remember this is not the first time I'm correcting things like this to work on Linux. Freeing NULL pointer buffers and so on... it is just very strange and unacceptable to me :).
Functionality for cut-in and cut-out could be added.