Ask Your Question

The-Log's profile - activity

2017-01-02 16:52:35 -0600 commented question Broken Tutorial for Video Reading and Writing C++?

Been doing that. Taking to a friend of mine and I believe its something that's related to macOS. I'll try testing with Linux.

2017-01-02 13:54:49 -0600 commented question Broken Tutorial for Video Reading and Writing C++?

Then I'll take it that the tutorial is broken as this is what their code returns.

2017-01-01 16:15:26 -0600 commented question Broken Tutorial for Video Reading and Writing C++?

It still gives a similar error, but it is now complaining about an array being out of bounds.

2017-01-01 16:13:31 -0600 received badge  Editor (source)
2016-12-31 13:26:47 -0600 asked a question Broken Tutorial for Video Reading and Writing C++?

Hi I was trying to use this tutorial to do some video manipulation with OpenCV, but the program there doesn't seem to even run and results in this error:

    2016-12-31 14:17:14.509 process[9002:114718] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[AVAssetWriterInput initWithMediaType:outputSettings:sourceFormatHint:] AVVideoSettings dictionary must specify a positive width'
*** First throw call stack:
(
    0   CoreFoundation                      0x00007fffcf4d20db __exceptionPreprocess + 171
    1   libobjc.A.dylib                     0x00007fffe4164a2a objc_exception_throw + 48
    2   AVFoundation                        0x00007fffcbb6e728 -[AVAssetWriterInput dealloc] + 0
    3   AVFoundation                        0x00007fffcbb6e0b3 +[AVAssetWriterInput assetWriterInputWithMediaType:outputSettings:] + 52
    4   libopencv_highgui.2.4.dylib         0x0000000107139132 _ZN26CvVideoWriter_AVFoundationC2EPKcid6CvSizei + 682
    5   libopencv_highgui.2.4.dylib         0x0000000107136dd3 _Z32cvCreateVideoWriter_AVFoundationPKcid6CvSizei + 69
    6   libopencv_highgui.2.4.dylib         0x000000010712a848 cvCreateVideoWriter + 80
    7   libopencv_highgui.2.4.dylib         0x000000010712b24a _ZN2cv11VideoWriter4openERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEidNS_5Size_IiEEb + 58
    8   process                             0x0000000106c11fa0 main + 1232
    9   libdyld.dylib                       0x00007fffe4a46255 start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
Abort trap: 6

Is it broken or am I doing something wrong when running the program? Thanks!

EDIT: Using the newer tutorial changes the error to this:

2017-01-01 17:09:59.972 process[17637:327510] *** Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[__NSArrayM objectAtIndex:]: index 0 beyond bounds for empty array'
*** First throw call stack:
(
    0   CoreFoundation                      0x00007fffcf4d20db __exceptionPreprocess + 171
    1   libobjc.A.dylib                     0x00007fffe4164a2a objc_exception_throw + 48
    2   CoreFoundation                      0x00007fffcf3ee4fb -[__NSArrayM objectAtIndex:] + 203
    3   libopencv_highgui.2.4.dylib         0x000000010285f280 _ZN13CvCaptureFileC2EPKc + 350
    4   libopencv_highgui.2.4.dylib         0x000000010285dcf2 _Z32cvCreateFileCapture_AVFoundationPKc + 34
    5   libopencv_highgui.2.4.dylib         0x00000001028517ee cvCreateFileCapture + 14
    6   libopencv_highgui.2.4.dylib         0x0000000102851a9e _ZN2cv12VideoCapture4openERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEE + 64
    7   libopencv_highgui.2.4.dylib         0x00000001028518fe _ZN2cv12VideoCaptureC2ERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEE + 42
    8   process                             0x000000010232f9ad main + 349
    9   libdyld.dylib                       0x00007fffe4a46255 start + 1
    10  ???                                 0x0000000000000004 0x0 + 4
)
libc++abi.dylib: terminating with uncaught exception of type NSException
Abort trap: 6