Author Topic: Video is shortened when using crop filter + swsResize  (Read 3276 times)

ckwms

  • Newbie
  • *
  • Posts: 5
Video is shortened when using crop filter + swsResize
« on: April 22, 2016, 07:12:09 PM »
Hi. I have a little problem with Avidemux. I don't know if this is the right place to post it, but I don't know where else I should.

When I import a video in Avidemux, and I use the crop tool and swsResize, the saved video is only 3 seconds long, while the original video is much longer, like 18 minutes or so. I don't know why this happens. When I save the video Avidemux says that saving the file was successful. Also, in the preview after using the crop filter and swsResize the video is 18 minutes. I don't know why the saved file is much shorter, any help is appreciated.

Jan Gruuthuse

  • Hero Member
  • *****
  • Posts: 6060
Re: Video is shortened when using crop filter + swsResize
« Reply #1 on: April 22, 2016, 07:22:31 PM »
Can you provide more info?
Used avidemux version (2.5.6, 2.6.12, ... / build)
Kind of video you import, container, used codecs (video/audio), how many audio tracks? kind of tracks mono, stereo, ac3, mp2?
What video output are you using?
What muxer are you using in Output Format?

ckwms

  • Newbie
  • *
  • Posts: 5
Re: Video is shortened when using crop filter + swsResize
« Reply #2 on: April 23, 2016, 12:19:30 PM »
Can you provide more info?
Used avidemux version (2.5.6, 2.6.12, ... / build)
Kind of video you import, container, used codecs (video/audio), how many audio tracks? kind of tracks mono, stereo, ac3, mp2?
What video output are you using?
What muxer are you using in Output Format?
I use Avidemux 2.6.11. The kind of video I import is an .avi with Xvid codec. The audio codec is MPEG-1 L2. I don't know how many audio tracks but I think 1. The track(s) is/are stereo.

The video output I use in Avidemux is Mpeg4 ASP (xvid4). I use the AVI Muxer.

Jan Gruuthuse

  • Hero Member
  • *****
  • Posts: 6060
Re: Video is shortened when using crop filter + swsResize
« Reply #3 on: April 23, 2016, 02:29:52 PM »
just tested
Mpeg4 ASP (xvid4) + MP2 (lav) in avi muxer, this should work.

avidemux should show the tracks in the video on left hand side in the middle.
Audio Output (1 track(s))
If you have indicating more then 1 track: check avidemux menu: Audio: Select Track.
This should show you what the other tracks are.

What resolution are you
- Size from cropping to?
- resizing to?

meanwhile try upgrade to 2.6.12 with one form the nightly 32 or 64 bit according your OS:
http://www.avidemux.org/nightly/
« Last Edit: April 23, 2016, 04:19:36 PM by Jan Gruuthuse »

ckwms

  • Newbie
  • *
  • Posts: 5
Re: Video is shortened when using crop filter + swsResize
« Reply #4 on: April 23, 2016, 06:53:11 PM »
just tested
Mpeg4 ASP (xvid4) + MP2 (lav) in avi muxer, this should work.

avidemux should show the tracks in the video on left hand side in the middle.
Audio Output (1 track(s))
If you have indicating more then 1 track: check avidemux menu: Audio: Select Track.
This should show you what the other tracks are.

What resolution are you
- Size from cropping to?
- resizing to?

meanwhile try upgrade to 2.6.12 with one form the nightly 32 or 64 bit according your OS:
http://www.avidemux.org/nightly/

Ah, I now see that I have 1 audio track. I just updated to 2.6.12.

The original size of the video is 1280x720. I Crop the bottom ~150/160, I uncheck the Lock Aspect Ratio and change the height from 560 back to the original 720. The Resize Method I use in swsResize is the standard Lanzcos3. I tried the settings you suggested but it still doesn't work for me.

Jan Gruuthuse

  • Hero Member
  • *****
  • Posts: 6060
Re: Video is shortened when using crop filter + swsResize
« Reply #5 on: April 23, 2016, 07:57:41 PM »
I've tested like you indicated:
original: Original dvb-s2 recording 3satHD 720p
result: YouTube: 720p cropped swresized

Can you download the same test video 720p4audioTracks3sat.ts 69 MB and do the same with this video.
- crop bottom -160
- uncheck the Lock Aspect Ratio
- swsResize back to 720p

ckwms

  • Newbie
  • *
  • Posts: 5
Re: Video is shortened when using crop filter + swsResize
« Reply #6 on: April 23, 2016, 08:26:53 PM »
This is strange, it works with your test video. I don't know why it doesn't work with the videos that I record. For recording I use Bandicam, but I think it shouldn't matter which recording software I use.

Jan Gruuthuse

  • Hero Member
  • *****
  • Posts: 6060
Re: Video is shortened when using crop filter + swsResize
« Reply #7 on: April 23, 2016, 08:42:10 PM »
most likely it is the way the video is recorded.
See if it works with avidemux 2.5.6: Download avidemux 2.5.6 32 or 64 bit (by: gruntster)
Sometimes it is better to work with frame based (avidemux 2.5.x). Newer codecs work better with time based (avidemux 2.6.x.)
If this still is an issue, please upload a sample recording, 10 seconds should do, so developer can have a look at it.

ps:- Use a free dropbox account, mega or similar webservice (free public access, without registration to download your uploaded video) thank you.

if you have the choice for recording:
Quote
Summary: If you can choose H.264 encoder in Bandicam, choose "H.264"

Read more: https://www.bandicam.com/support/tips/best-codec/
« Last Edit: April 23, 2016, 08:51:20 PM by Jan Gruuthuse »

ckwms

  • Newbie
  • *
  • Posts: 5
Re: Video is shortened when using crop filter + swsResize
« Reply #8 on: April 24, 2016, 04:10:02 PM »
Thanks man, I tested it with 2 different videos and it worked both times! And thanks for the tip for choosing the H.264 encoder in Bandicam.

Jan Gruuthuse

  • Hero Member
  • *****
  • Posts: 6060
Re: Video is shortened when using crop filter + swsResize
« Reply #9 on: April 24, 2016, 04:50:31 PM »
your welcome