Commit Graph

3043 Commits

Author SHA1 Message Date
Isaac Connor 302189a65e Don't use camera->LineSize when allocating shared images. It doesn't work because other processes don't know about it. 2020-08-06 10:11:00 -04:00
Isaac Connor be05040a47 fix rotated images 2020-07-30 19:50:25 -04:00
Isaac Connor 05107bb2f7 Add debug of unused options 2020-07-30 15:16:31 -04:00
Isaac Connor d8cd4386cf rename GetOptEncoderParams to GetOptEncoderParams to GetOptEncoderParamsVec so that we can get at the std::string if we want to.
Use EncoderParams when setting movflags in VideoStore.

Move the content of this option to a help popup so that we can remove the comments from it. av_dict_parse doesn't handle the hash tag as a comment.
2020-07-30 15:06:05 -04:00
Isaac Connor 4ed0ad26a7 bail early if fwrite fails 2020-07-29 14:01:52 -04:00
Isaac Connor b1054a7db6 bail earlier if writing content-length fails. Dropped connections aren't really errors, make them Info. Fixes #2996 2020-07-29 13:39:00 -04:00
Isaac Connor 7e6c637ec3 Unexpected colours while bad should only cause failure to annotate, not panic 2020-07-22 11:34:54 -04:00
Isaac Connor 5c844f9cae remove extra space 2020-07-20 10:22:40 -04:00
Isaac Connor 01892352da rename sseversion to sse_version 2020-07-19 17:50:47 -04:00
Isaac Connor 6b39f59b3a use delete[] instead of delete. 2020-07-16 16:00:23 -04:00
Isaac Connor 2c056c188f Fix compile on old ffmpeg 2020-07-16 15:59:08 -04:00
Isaac Connor 4e2732e12d Priming capture logs should be debug not Info 2020-07-16 15:51:24 -04:00
Isaac Connor a7b76dfe41 Remove debug 2020-07-16 15:48:09 -04:00
Isaac Connor 0a6321ee56 Update linesize when using AssignDirect. Fixes #2979 2020-07-16 15:48:06 -04:00
Isaac Connor d849ee54a4 Update state to ALARM AFTER we have opened the event, so that we get the correct event Id. Fixes #2978 Fixes #2894 2020-07-16 15:47:01 -04:00
Isaac Connor 9b447bde8e remove extra { 2020-07-07 18:56:51 -04:00
Isaac Connor 916d1ed59e Merge branch 'release-1.34' of github.com:ZoneMinder/zoneminder into release-1.34 2020-07-07 16:15:23 -04:00
Isaac Connor c79c65e72e spacing fixes 2020-07-07 16:14:57 -04:00
Isaac Connor af74ecac4c Pass along the image linesize to Image constructors so that Image knows about the requirement for it to be 32byte aligned. 2020-07-07 16:14:38 -04:00
Isaac Connor fd9272241a Introduce constructors that can be passed a linesize which is the # of bytes to use to store a line of image. This can be different from the image width * colours as it should be 32byte aligned for use with sws_scale. 2020-07-07 16:13:41 -04:00
Isaac Connor cae8978501 add an alignment variable to ffmpeg_camera to use wherever we want to tell ffmpeg about the buffer and linesize alignment. Figure out linesize in the constructor so that zm_monitor can pass the info along to zm_image. 2020-07-07 16:12:14 -04:00
Isaac Connor 533876f313 rewrite code to use fewer lines. No logic change. 2020-07-07 09:16:42 -04:00
Isaac Connor 864cd4c178 introduce a linesize variable which represents the # of bytes to hold a line of the image in the buffer. May be > width * colours 2020-07-05 17:51:57 -04:00
Isaac Connor e137e1dacf Don't consult EVENT_CLOSE_MODE if mode is RECORD 2020-06-26 19:30:35 -04:00
Isaac Connor 728f41fe9c Log @debug when a linked monitor is disconnected. Use ZM_MAX_RESTART_DELAY instead of hard coded 60 seconds before next reconnect attempt 2020-06-23 16:56:35 -04:00
Isaac Connor 31a3be5c8e check shared_data->valid when checking if LinkedMonitor is connected 2020-06-23 15:05:17 -04:00
Isaac Connor 2637c887f8 Fix segfault when timestamp contains an unimplemented character. Fixes #2943 2020-05-29 11:44:34 -04:00
Isaac Connor 9ea1c637f9 Remove debug Exiting message 2020-05-15 11:48:41 -04:00
Isaac Connor 7a85be59be Remove errant closing db debug output 2020-05-15 10:22:58 -04:00
Isaac Connor 25a772c5eb reorder logic a bit to make it easier to read. Make exit_zmu not return a value. 2020-05-14 12:02:02 -04:00
Isaac Connor 16e7ca5a51 failure opening a monitor should not be fatal. 2020-05-14 12:01:24 -04:00
Isaac Connor 402c0c6a1b Fix build on older ffmpeg 2020-05-14 12:01:03 -04:00
Isaac Connor efbab4e2bc Dont' call mysql_library_end as it segfaults and hangs. 2020-05-14 12:00:36 -04:00
Isaac Connor bbf64de40e If there is a failure when decoding due to lack of support for the codec profile, re-init without hwaccel 2020-05-13 08:04:53 -04:00
Isaac Connor 1f6e68c129 Merge branch 'release-1.34' of github.com:ZoneMinder/zoneminder into release-1.34 2020-05-08 17:26:02 -04:00
Isaac Connor eca56c7123 Provide a more useful error message when the monitor's function is set to NONE. Fixes #2877 2020-05-01 19:21:20 -04:00
Isaac Connor ef540aa972 sun_path is defined to be 108 bytes. No need for 4095. Quiets compiler warnings 2020-05-01 19:13:50 -04:00
Joe540 c9f04c9136 Support event_close_mode for record mode
Support event_close_mode for record mode (with linked monitor)
2020-05-01 19:10:23 -04:00
Isaac Connor 6098c4c961 properly close streams and free memory in ffmpeg_input destructor 2020-05-01 19:03:18 -04:00
Isaac Connor c5cf6e1a74 undo random addition 2020-05-01 19:01:09 -04:00
Isaac Connor 050868fad1 fix build on libavtools < 12 2020-05-01 19:00:40 -04:00
Isaac Connor 9beb5cee3a use delete[] instead of delete. 2020-05-01 18:55:48 -04:00
Isaac Connor 24aaeee155 dynamically load monitor Object when loading event data. Also dynamically load Storage, but only when the Id is different. Free the various objects in the destructor. Sync up some spacing issues with master. 2020-05-01 18:44:35 -04:00
Isaac Connor 2071b2a71e Guess video file name for in progress events 2020-05-01 18:14:58 -04:00
Isaac Connor 917c43a54b If can't connect to db, bail instead of loading config 2020-05-01 18:08:32 -04:00
Isaac Connor f96cc66b9d google code style 2020-05-01 18:06:27 -04:00
Isaac Connor ffcef8a42a spacing and make sws_context static global so we don't have to keep initializing it when playing back from mp4 in eventstream. 2020-05-01 15:22:32 -04:00
Isaac Connor 14b90903a9 Merge branch 'release-1.34' of github.com:ZoneMinder/zoneminder into release-1.34 2020-05-01 12:50:10 -04:00
Isaac Connor 3b11258fbc Make checkEventLoaded return true if a new event was loaded, false otherwise. The idea is to give more information back to whoever calls it 2020-04-26 15:22:29 -04:00
Isaac Connor 3dd5ac8146 shrink buffers for writing timestamp into. Don't need 64 when 28 will do. Quiets compiler warnings 2020-04-24 16:43:27 -04:00