Commit Graph

312 Commits

Author SHA1 Message Date
Isaac Connor
db135cba46 Add isPrimed to camera class instead of it just being in ffmpeg_camera. Rename mCanCapture to isPrimed in ffmpeg_camera. 2023-12-06 09:38:38 -05:00
Isaac Connor
558aed0561 Fix memleak due to not freeing the opts dict except on error. 2023-10-26 13:44:02 -04:00
Isaac Connor
3f7e9d57ae Put back code to free audio context and codec. If we aren't useing second input, we still need to free them. 2023-10-20 10:51:44 -04:00
Isaac Connor
7eb601ef4d Restore audio recording 2023-09-13 10:47:45 -04:00
David Schmidt
5bfa28d172 Use unique_ptr instread of local scope object pointer for second input 2023-09-09 18:51:54 +02:00
Isaac Connor
9295c390ca re-parse Options into opts so that they are available to open_codec 2023-07-28 17:39:08 -04:00
Isaac Connor
ef29805a4d Test for word auto in decodername and don't do lookup for it 2023-07-17 17:01:39 -04:00
Isaac Connor
0a0293f34a Turn warning about mismatched dimensions into a debug 2023-06-12 10:17:11 -04:00
Isaac Connor
f8ca7cee94 Cleanup constructor a bit 2023-06-08 10:58:08 -04:00
Isaac Connor
ab9298cbf0 Add DecoderName to Monitors, and use it in ffmpeg_camera instead of just trying all options 2023-02-26 16:30:56 -05:00
Isaac Connor
c1c25aeb76 Add sqv hwaccel types 2023-02-25 18:07:54 -05:00
Isaac Connor
7a1066c534 Disable multi-threaded decoding as a test 2023-01-26 18:46:38 -05:00
Isaac Connor
32add0952c Differentiate between negative pts and AV_NOPTS_VALUE when looking for wrap around. 2023-01-10 14:19:40 -05:00
Isaac Connor
0d569c26d7 fix formatting string 2023-01-07 12:35:24 -05:00
Isaac Connor
090b90565f Add uriencoding of the password 2023-01-06 12:22:04 -05:00
Isaac Connor
48c18ca4ed Attempt to better handle 32bit wrap around in the pts in the input stream. 2022-12-23 09:02:41 -05:00
AngeloGioacchino Del Regno
7f8badc334 zm_ffmpeg_camera: Add support for Jetson Nano/Xavier NVMPI
Add support for the NVMPI hardware decoders (not CUDA decoders!)
of the Tegra SoCs found in the Jetson Nano/TX/TX2 and Xavier NX/AGX.

This platform supports hardware decoding of H264, HEVC, MPEG2,
MPEG4, VP8 and VP9.
2022-11-24 00:09:02 +01:00
Isaac Connor
dd82a01291 Don't encode the user/pass. If they were properly entered in the web ui then we will double encode them. 2022-09-18 12:35:04 -04:00
Isaac Connor
e1d381bc9e Don't set auth_type. It doesn't seem to be support and shouldn't be necessary 2022-08-22 11:46:36 -04:00
parvit (Vittorio Parrella)
a94d74143e support for ffmpeg type camera authentication with special characters 2022-08-20 10:01:14 -04:00
Doug Nazar
acbdf1854d Add guard to handle resetting AVPacket after use.
Also handle allocation failures.
2022-07-29 14:56:38 -04:00
Doug Nazar
110cc436a3 Switch from av_init_packet() to av_packet_alloc()
Remove all uses of deprecated av_init_packet() and switch any stack
based AVPackets to unique_ptrs allocated with av_packet_alloc().

Ensure that all code paths call av_packet_unref() after use to reset
before next usage.
2022-07-29 14:56:26 -04:00
Isaac Connor
a5ef240e96 Use remove_authentication instead of mask_authentication 2022-07-04 11:02:02 -04:00
Isaac Connor
e6eb94760c Use MaskedPath when logging failure to open 2022-06-22 11:13:43 -04:00
Isaac Connor
984c08049b fix compile on < ffmpeg5 2022-05-18 17:12:06 -04:00
Isaac Connor
61c5f9aad3 ffmpeg5 fix by adding const 2022-05-18 16:29:49 -04:00
Isaac Connor
65efe6977f Merge pull request #3466 from ZoneMinder/mask_password
Mask password
2022-04-28 16:23:37 -04:00
Isaac Connor
3ecffcb007 Initialize ret to suppress warning. 2022-04-25 10:07:57 -04:00
Isaac Connor
c15d2ac660 Use mOptions instead of Options(). Check for empty before parsing 2022-04-23 19:12:30 -04:00
Isaac Connor
ff46f78ab4 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2022-04-19 17:08:19 -04:00
Isaac Connor
5672b2c195 Try out options to improve latency 2022-04-19 17:08:16 -04:00
Isaac Connor
510983c2e4 Add support for v4l2 input types in ffmpeg_camera. 2022-04-18 18:04:46 -04:00
Isaac Connor
57fdbda7ec add mMaskedPath and mMaskedSecondPath and use them when logging so that usernames and passwords are shown in logs. Fixes #3118 2022-04-18 13:33:58 -04:00
Isaac Connor
513c228ff3 Merge branch 'master' of github.com:ZoneMinder/zoneminder 2022-04-03 16:29:15 -04:00
Isaac Connor
7c5a6f9bae Cleanups. Return if we don't find a video stream. Also check for width and height on video streams 2022-04-03 16:23:51 -04:00
Exuvo
d1395dab9a Fix ffmpeg 5 const errors 2022-03-11 21:40:25 +01:00
Isaac Connor
ed7bc7c4b4 whitespace 2022-01-10 15:25:15 -05:00
Isaac Connor
a76128e9c4 include monitor->Importance when logging failed camera connects 2022-01-01 18:56:13 -05:00
Isaac Connor
96b4af6255 Enable multi-threading on decode 2021-11-17 14:43:13 -05:00
Isaac Connor
ac375bc623 fix errant = 2021-09-27 11:03:29 -04:00
Isaac Connor
202d95fc5a handle AV_HWDEVICE_TYPE_MMAL not being defined 2021-09-27 10:58:16 -04:00
Isaac Connor
aae967e895 Add mmal device/pix fmt type 2021-09-23 16:39:35 -04:00
Isaac Connor
30fa641186 initialize video_first_pts and when setting it need to specify microseconds otherwise we get nanoseconds. White space. 2021-09-21 14:29:05 -04:00
Peter Keresztes Schmidt
d69afc9672 misc: Convert time(nullptr) calls to std::chrono 2021-06-13 23:22:51 +02:00
Peter Keresztes Schmidt
2d71743372 FFmpeg: Remove code paths required only by 2.8 and older
With Xenial support dropped we require FFmpeg 3.2 and newer.
2021-06-05 20:40:12 +02:00
Peter Keresztes Schmidt
0625f6ca1c Misc: Cleanup some includes 2021-06-05 15:08:38 +02:00
Peter Keresztes Schmidt
762476ec76 Build: Promote libswscale to a required dependency
FFmpeg is an integral component of ZM. Promote the appropriate libraries to required dependencies.
This reduces the possible build configurations greatly and thus maintenance burden.
2021-06-05 14:27:31 +02:00
Peter Keresztes Schmidt
7d15396833 Build: Promote libavformat to a required dependency
FFmpeg is an integral component of ZM. Promote the appropriate libraries to required dependencies.
This reduces the possible build configurations greatly and thus maintenance burden.
2021-06-05 14:25:27 +02:00
Isaac Connor
cca30661d7 remove invalid debug 2021-06-04 17:42:00 -04:00
Isaac Connor
205c488741 spacing 2021-06-04 15:01:57 -04:00