News:

--

Main Menu

[BUG] Can't process .AVI file

Started by dosdan, April 13, 2016, 12:04:00 PM

Previous topic - Next topic

dosdan

Source is a 10sec .AVI created by using x264vfw from within Sony Vegas 12. File is available here:

https://dl.dropbox.com/s/m1wxpncrnai3ik2/x264vfw_test.avi

It plays OK in MPC.

This AVI has MPEG4-AVC video + PCM audio. I wanted to compress the audio into AAC and remux into MP4.  However when I load this file in ADM 2.6.12 Release and use even just a simple V:Copy + A:Copy, muxed into either MP4 or a new AVI, when saving, it crashes with:

Assert failed:0 in line 534, file /home/fx/hudson/workspace/mingw64QT5/avidemux/qt4/common/ADM_editor/src/ADM_segment.cpp

Details:
ADM_setCrashHook  [libADM_core6.dll]
ADM_setCrashHook  [libADM_core6.dll]
ADM_backTrack  [libADM_core6.dll]
ADM_EditorSegment::intraTimeToFrame(unsigned int, unsigned long long)  [avidemux.exe]
ADM_Composer::GoToIntraTime_noDecoding(unsigned long long, unsigned int*)  [avidemux.exe]
ADM_videoStreamCopy::ADM_videoStreamCopy(unsigned long long, unsigned long long)  [avidemux.exe]
admSaver::setupVideo()  [avidemux.exe]
admSaver::save()  [avidemux.exe]
A_Save(char const*)  [avidemux.exe]
A_SaveWrapper(char const*)  [avidemux.exe]
ADM_QT4_fileSel::GUI_FileSelWriteExtension(char const*, char const*, void (*)(char const*))  [avidemux.exe]
HandleAction_Save(Action)  [avidemux.exe]
HandleAction(Action)  [avidemux.exe]
MainWindow::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)  [avidemux.exe]
QMetaObject::activate(QObject*, int, int, void**)  [Qt5Core.dll]
MainWindow::actionSignal(Action)  [avidemux.exe]
MainWindow::searchFileMenu(QAction*)  [avidemux.exe]
MainWindow::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)  [avidemux.exe]
QMetaObject::activate(QObject*, int, int, void**)  [Qt5Core.dll]
QMenu::setPlatformMenu(QPlatformMenu*)  [Qt5Widgets.dll]
QMenu::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)  [Qt5Widgets.dll]
QMetaObject::activate(QObject*, int, int, void**)  [Qt5Core.dll]
QAction::activate(QAction::ActionEvent)  [Qt5Widgets.dll]
QMenu::setIcon(QIcon const&)  [Qt5Widgets.dll]
QMenu::internalDelayedPopup()  [Qt5Widgets.dll]
QMenu::mouseReleaseEvent(QMouseEvent*)  [Qt5Widgets.dll]
QWidget::event(QEvent*)  [Qt5Widgets.dll]
QMenu::event(QEvent*)  [Qt5Widgets.dll]
QApplicationPrivate::notify_helper(QObject*, QEvent*)  [Qt5Widgets.dll]
QApplication::notify(QObject*, QEvent*)  [Qt5Widgets.dll]
QCoreApplication::notifyInternal(QObject*, QEvent*)  [Qt5Core.dll]
QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool)  [Qt5Widgets.dll]
non-virtual thunk to QWidget::metric(QPaintDevice::PaintDeviceMetric) const  [Qt5Widgets.dll]
non-virtual thunk to QWidget::metric(QPaintDevice::PaintDeviceMetric) const  [Qt5Widgets.dll]
QApplicationPrivate::notify_helper(QObject*, QEvent*)  [Qt5Widgets.dll]
QApplication::notify(QObject*, QEvent*)  [Qt5Widgets.dll]
QCoreApplication::notifyInternal(QObject*, QEvent*)  [Qt5Core.dll]
QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*)  [Qt5Gui.dll]
QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*)  [Qt5Gui.dll]
QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>)  [Qt5Gui.dll]
QEventDispatcherWin32Private::sendTimerEvent(int)  [Qt5Core.dll]
DispatchMessageW  [USER32.dll]
DispatchMessageW  [USER32.dll]
QEventDispatcherWin32::processEvents(QFlags<QEventLoop::ProcessEventsFlag>)  [Qt5Core.dll]
unknown function  [qwindows.dll]
QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>)  [Qt5Core.dll]
QCoreApplication::exec()  [Qt5Core.dll]
myQApplication::exec()  [avidemux.exe]
UI_RunApp()  [avidemux.exe]
startAvidemux(int, char**)  [avidemux.exe]
SDL_main  [avidemux.exe]
console_main  [avidemux.exe]
WinMain  [avidemux.exe]
unknown function  [avidemux.exe]
unknown function  [avidemux.exe]
BaseThreadInitThunk  [KERNEL32.DLL]
RtlUserThreadStart  [ntdll.dll]


Dan.



Jan Gruuthuse

#1
Could be, there is something wrong with that video. Perhaps you can use something other then VideoForWindows in Vegas
When trying to save (linux ubuntu) this pops up:
Assert failed :0
at line 534, file /home/jan/avidemux2/avidemux/qt4/common/ADM_editor/src/ADM_segment.cppADM_backTrack
ADM_EditorSegment::intraTimeToFrame(unsigned int, unsigned long)
ADM_Composer::GoToIntraTime_noDecoding(unsigned long, unsigned int*)
ADM_videoStreamCopy::ADM_videoStreamCopy(unsigned long, unsigned long)
ADM_videoStreamCopyFromAnnexB::ADM_videoStreamCopyFromAnnexB(unsigned long, unsigned long)
admSaver::setupVideo()
admSaver::save()
A_Save(char const*)
A_SaveWrapper(char const*)
ADM_QT4_fileSel::GUI_FileSelWriteExtension(char const*, char const*, void (*)(char const*))
HandleAction_Save(Action)
HandleAction(Action)
/usr/bin/avidemux3_qt4() [0x488fc4]
QMetaObject::activate(QObject*, QMetaObject const*, int, void**)
MainWindow::actionSignal(Action)
MainWindow::searchToolBar(QAction*)
/usr/bin/avidemux3_qt4() [0x489260]
QMetaObject::activate(QObject*, QMetaObject const*, int, void**)
QToolBar::actionTriggered(QAction*)

QMetaObject::activate(QObject*, QMetaObject const*, int, void**)
QToolButton::triggered(QAction*)

QMetaObject::activate(QObject*, QMetaObject const*, int, void**)
QAction::triggered(bool)
QAction::activate(QAction::ActionEvent)

QAbstractButton::mouseReleaseEvent(QMouseEvent*)
QToolButton::mouseReleaseEvent(QMouseEvent*)
QWidget::event(QEvent*)


Perhaps developers do see something.
If this is urgent:
Re-mux this type of video with "MKVToolNix ââ,¬â€œ Matroska tools for Linux/Unix and Windows" and then you can process the newly .mkv with avidemux
see end/download result: x264vfw_test-aac.mp4

AQUAR

#2
ADM forces an exit because of this bit of code.
 
533 ADM_error("Cannot find frame with time %"PRIu64"ms\n",seekTime/1000);
534             ADM_assert(0);

A seek error to an unreferenced frame?

Just thinking that PCM audio takes up a lot of memory and maybe causing this issue.
Try extracting the audio and recode it separately (then remux it back in).

Note: its just a thought that would lead me to follow it through to see the outcome (most probably its some other issue!).

dosdan

#3
Jan, thanks for the MKVToolNix GUI workaround. Any idea why remuxing this AVI to MKV stops the ADM error?

AQUAR, don't think this is a memory issue related to PCM audio, as the MKV contains the same PCM stream, and it processes correctly in ADM.

Dan.

mean

Some critical informations are missing in avi fiile
So it would create a half broken mkv

Hence it fails, pretty badly

Bottom line : dont put h264 in avi, it's a very bad idea

dosdan

Quote from: mean on June 28, 2016, 10:54:13 AM
Bottom line : dont put h264 in avi, it's a very bad idea

Unfortunately, it's the only container offered when using VFW in Vegas Pro 12.   

I was having issues with ADM from a recent nightly build falling over part-way though the conversion of all 4 MKVs (from AVIs) to MP4s, but I tried again yesterday with a new nightly (160713) and it's now working OK.

The workflow & change-of-output is:


Vegas -> MKVToolNix GUI -> Avidemux

AVI (V: H.264, A: PCM) -> MKV (V: H.264, A: PCM) -> MP4 (V: H.264, A: AAC)


From what I've seen, the results from x264 CRF encoding are better than from either the MainConcept or Sony AVC encoders included in Vegas 12. This is probably due to the large amount of ongoing development for this well-respected open-source encoder. Also using x264 gives me a lot more flexibility in the encoding parameters I can use.


Dan.