mobile CCTV,mobile surveillance,police body worn cameras

 forgetPW
 registerNow
search
view: 1582|reply: 3
打印 prevThread nextThread

开启录像 出现卡顿

[copyURL]

73

主题

319

帖子

1121

积分

vipMem

Rank: 6Rank: 6

积分
1121
jumpTo
owner
poston 2019-6-1 17:55 | authorOnly 回帖奖励 |倒序浏览 |阅读模式
在使用mpu过程中,发现开始录像,相机卡顿接近3秒才开始录像,分析发现卡顿的从[size=13.3333px]AediaCodec_start success!到[size=13.3333px]Storage : get sps_pps success!sps_pps_size耗时了[size=13.3333px]想问下什么情况下才会出现卡顿
[size=13.3333px]

[size=13.3333px]相比较 异常的log在下面这一段耗时了

[size=13.3333px]05-30 16:21:29.002 8756 12484 I codec_omxal: AMediaCodec_configure success!
[size=13.3333px]05-30 16:21:29.022 8756 12484 I codec_omxal: AMediaCodec_start success!
[size=13.3333px]05-30 16:21:32.223 8756 12477 I Storage : get sps_pps success!sps_pps_size = 29


[size=13.3333px]正常的如下

[size=13.3333px]06-01 17:32:16.532 6577-7274/? I/codec_omxal: AMediaCodec_configure success!
[size=13.3333px]06-01 17:32:16.554 6577-7274/? I/codec_omxal: AMediaCodec_start success!
[size=13.3333px]06-01 17:32:16.659 6577-7267/? I/Storage: get sps_pps success!sps_pps_size = 29
[size=13.3333px]

[size=13.3333px]

[size=13.3333px]正常的log
06-01 17:32:16.288 6577-6577/? I/com.smarteye.control.RecordControl:  [ACTION] [000000] [000000] ¿aê¼Â¼Ïñ
06-01 17:32:16.288 6577-6577/? D/AIWINN_BASE: [ CameraHolder ] before increment count=1
06-01 17:32:16.288 6577-6577/? D/AIWINN_BASE: [ CameraHolder ] after increment count=2
06-01 17:32:16.290 6577-6577/? I/selectCodec: SelectCodec : OMX.qcom.video.encoder.hevc
06-01 17:32:16.291 6577-6577/? I/selectCodec: SelectCodec : OMX.qcom.video.encoder.hevc
06-01 17:32:16.291 6577-6577/? I/selectCodec: SelectCodec : OMX.qcom.video.encoder.hevc
06-01 17:32:16.291 6577-6577/? D/AudioHelper: bCapture = 1
06-01 17:32:16.295 6577-7267/? I/Storage: StorageThread::run
06-01 17:32:16.296 6577-7267/? I/codec_omxal: m_encode.iEncoderType = 0, m_out = 0xc67790d0, m_encode.iColorFormat = 1
06-01 17:32:16.306 6577-7264/? D/AudioHelper: audio record....
06-01 17:32:16.311 6577-6577/? E/ExtMediaPlayer-JNI: env->IsInstanceOf fails
06-01 17:32:16.311 6577-6577/? E/MediaPlayer-JNI: JNIMediaPlayerFactory: bIsQCMediaPlayerPresent 0
06-01 17:32:16.311 6577-6577/? E/ExtMediaPlayer-JNI: env->IsInstanceOf fails
06-01 17:32:16.311 6577-6577/? E/MediaPlayer-JNI: JNIMediaPlayerFactory: bIsQCMediaPlayerPresent 0
06-01 17:32:16.327 6577-6577/? D/MediaPlayer: setSubtitleAnchor in MediaPlayer
06-01 17:32:16.335 6577-7273/? I/MPU_Codec: SAVThread::run.............
06-01 17:32:16.336 6577-7274/? I/codec_omxal: VideoEncode::run tid = 7274 m_yuvDst = 0x0
06-01 17:32:16.336 6577-7274/? I/codec_omxal: AMediaCodec_createEncoderByType szMimeType=video/avc
06-01 17:32:16.350 6577-7276/? I/OMXClient: MuxOMX ctor
06-01 17:32:16.426 6577-6577/? I/codec_omxal: ..........dt enc
06-01 17:32:16.468 6577-6577/? I/codec_omxal: ..........dt enc
06-01 17:32:16.471 6577-7274/? I/codec_omxal: AMediaCodec_createEncoderByType success
06-01 17:32:16.473 6577-7276/? E/ACodec: [OMX.qcom.video.encoder.avc] storeMetaDataInBuffers (output) failed w/ err -1010
06-01 17:32:16.480 6577-7276/? I/ExtendedACodec: setupVideoEncoder()
06-01 17:32:16.481 6577-7276/? W/ACodec: do not know color format 0x7fa30c04 = 2141391876
06-01 17:32:16.481 6577-7276/? W/ACodec: do not know color format 0x7f000789 = 2130708361
06-01 17:32:16.496 6577-6577/? I/codec_omxal: ..........dt enc
06-01 17:32:16.520 6577-7276/? I/ACodec: setupAVCEncoderParameters with [profile: Baseline] [level: Level1]
06-01 17:32:16.523 6577-7276/? I/ACodec: [OMX.qcom.video.encoder.avc] cannot encode HDR static metadata. Ignoring.
06-01 17:32:16.523 6577-7276/? I/ACodec: setupVideoEncoder succeeded
06-01 17:32:16.523 6577-7276/? I/ExtendedACodec: [OMX.qcom.video.encoder.avc] configure, AMessage : AMessage(what = 'conf', target = 1) = {
                                                   string mime = "video/avc"
                                                   int32_t bitrate = 3686400
                                                   int32_t frame-rate = 25
                                                   int32_t color-format = 21
                                                   int32_t width = 1280
                                                   int32_t height = 720
                                                   int32_t max-width = 1280
                                                   int32_t max-height = 720
                                                   int32_t i-frame-interval = 1
                                                   int32_t stride = 1280
                                                   int32_t max-input-size = 1382400
                                                   int32_t encoder = 1
                                                 }
06-01 17:32:16.531 6577-6577/? I/codec_omxal: ..........dt enc
06-01 17:32:16.532 6577-7274/? I/codec_omxal: AMediaCodec_configure success!
06-01 17:32:16.554 6577-7274/? I/codec_omxal: AMediaCodec_start success!
06-01 17:32:16.659 6577-7267/? I/Storage: get sps_pps success!sps_pps_size = 29
06-01 17:32:16.934 6577-7267/? I/Storage: fileName=/sdcard/RST3/aiwinn/jarvis/media/Video/20190601_173216.mkv
06-01 17:32:16.934 6577-7267/? I/SAV: SAVContainer_Open
06-01 17:32:16.939 6577-7267/? I/Storage: /sdcard/RST3/aiwinn/jarvis/media/Video/20190601_173216.mkv create success!
06-01 17:32:16.940 6577-6577/? D/AIWINN_BASE: [ MPUService ] onMessageFromNative storage.file.info
06-01 17:32:16.941 6577-6577/? D/StorageFile: ---storage.file.info result {
                                                      "bFileMark":        false,
                                                      "bFileSecrecy":        false,
                                                      "szPUID":        "",
                                                      "szPUNAME":        "",
                                                      "szFilePath":        "/sdcard/RST3/aiwinn/jarvis/media/Video",
                                                      "szFileName":        "20190601_173216.mkv",
                                                      "szTriggerID":        "",
                                                      "iChannelIndex":        0,
                                                      "iFileDuration":        600,
                                                      "iFileType":        1,
                                                      "iFileStatus":        1,
                                                      "iRecordType":        1,
                                                      "szBeginTime":        "20190601_173216"
                                              }



[size=13.3333px]卡顿的log


05-30 16:21:28.879  8756  8756 I com.smarteye.control.RecordControl:  [ACTION] [000000] [000000] ¿aê¼Â¼Ïñ
05-30 16:21:28.879  8756  8756 D AIWINN_BASE: [ CameraHolder ] before increment count=3
05-30 16:21:28.879  8756  8756 D AIWINN_BASE: [ CameraHolder ] after increment count=4
05-30 16:21:28.879  8756  8756 I selectCodec: SelectCodec : OMX.qcom.video.encoder.hevc
05-30 16:21:28.879  8756  8756 I selectCodec: SelectCodec : OMX.qcom.video.encoder.hevc
05-30 16:21:28.879  8756  8756 I selectCodec: SelectCodec : OMX.qcom.video.encoder.hevc
05-30 16:21:28.879  8756  8756 D AudioHelper: bCapture = 2
05-30 16:21:28.881  8756 12477 I Storage : StorageThread::run
05-30 16:21:28.881  8756 12477 I codec_omxal: m_encode.iEncoderType = 0, m_out = 0xc0f233f0, m_encode.iColorFormat = 1
05-30 16:21:28.886  8756  8756 E ExtMediaPlayer-JNI: env->IsInstanceOf fails
05-30 16:21:28.886  8756  8756 E MediaPlayer-JNI: JNIMediaPlayerFactory: bIsQCMediaPlayerPresent 0
05-30 16:21:28.886  8756  8756 E ExtMediaPlayer-JNI: env->IsInstanceOf fails
05-30 16:21:28.886  8756  8756 E MediaPlayer-JNI: JNIMediaPlayerFactory: bIsQCMediaPlayerPresent 0
05-30 16:21:28.910  8756  8756 D MediaPlayer: setSubtitleAnchor in MediaPlayer
05-30 16:21:28.925  8756 12483 I MPU_Codec: SAVThread::run.............
05-30 16:21:28.926  8756 12484 I codec_omxal: VideoEncode::run tid = 12484 m_yuvDst = 0x0
05-30 16:21:28.926  8756 12484 I codec_omxal: AMediaCodec_createEncoderByType szMimeType=video/avc
05-30 16:21:28.929  8756 12486 I OMXClient: MuxOMX ctor
05-30 16:21:28.952  8756 12484 I codec_omxal: AMediaCodec_createEncoderByType success
05-30 16:21:28.953  8756 12486 E ACodec  : [OMX.qcom.video.encoder.avc] storeMetaDataInBuffers (output) failed w/ err -1010
05-30 16:21:28.953  8756 12486 I ExtendedACodec: setupVideoEncoder()
05-30 16:21:28.954  8756 12486 W ACodec  : do not know color format 0x7fa30c04 = 2141391876
05-30 16:21:28.955  8756 12486 W ACodec  : do not know color format 0x7f000789 = 2130708361
05-30 16:21:28.975  8756 12486 I ACodec  : setupAVCEncoderParameters with [profile: Baseline] [level: Level1]
05-30 16:21:28.981  8756 12486 I ACodec  : [OMX.qcom.video.encoder.avc] cannot encode HDR static metadata. Ignoring.
05-30 16:21:28.981  8756 12486 I ACodec  : setupVideoEncoder succeeded
05-30 16:21:28.982  8756 12486 I ExtendedACodec: [OMX.qcom.video.encoder.avc] configure, AMessage : AMessage(what = 'conf', target = 43) = {
05-30 16:21:28.982  8756 12486 I ExtendedACodec:   string mime = "video/avc"
05-30 16:21:28.982  8756 12486 I ExtendedACodec:   int32_t bitrate = 3686400
05-30 16:21:28.982  8756 12486 I ExtendedACodec:   int32_t frame-rate = 25
05-30 16:21:28.982  8756 12486 I ExtendedACodec:   int32_t color-format = 21
05-30 16:21:28.982  8756 12486 I ExtendedACodec:   int32_t width = 1280
05-30 16:21:28.982  8756 12486 I ExtendedACodec:   int32_t height = 720
05-30 16:21:28.982  8756 12486 I ExtendedACodec:   int32_t max-width = 1280
05-30 16:21:28.982  8756 12486 I ExtendedACodec:   int32_t max-height = 720
05-30 16:21:28.982  8756 12486 I ExtendedACodec:   int32_t i-frame-interval = 1
05-30 16:21:28.982  8756 12486 I ExtendedACodec:   int32_t stride = 1280
05-30 16:21:28.982  8756 12486 I ExtendedACodec:   int32_t max-input-size = 1382400
05-30 16:21:28.982  8756 12486 I ExtendedACodec:   int32_t encoder = 1
05-30 16:21:28.982  8756 12486 I ExtendedACodec: }
05-30 16:21:29.002  8756 12484 I codec_omxal: AMediaCodec_configure success!
05-30 16:21:29.022  8756 12484 I codec_omxal: AMediaCodec_start success!
05-30 16:21:32.223  8756 12477 I Storage : get sps_pps success!sps_pps_size = 29
05-30 16:21:32.239  8756 12477 I Storage : fileName=/sdcard/RST3/aiwinn/jarvis/media/Video/20190530_162132.mkv
05-30 16:21:32.239  8756 12477 I SAV     : SAVContainer_Open
05-30 16:21:32.243  8756 12477 I Storage : /sdcard/RST3/aiwinn/jarvis/media/Video/20190530_162132.mkv create success!
05-30 16:21:32.245  8756  8756 D AIWINN_BASE: [ MPUService ] onMessageFromNative storage.file.info
05-30 16:21:32.245  8756  8756 D StorageFile: ---storage.file.info result {
05-30 16:21:32.245  8756  8756 D StorageFile:         "bFileMark":        false,
05-30 16:21:32.245  8756  8756 D StorageFile:         "bFileSecrecy":        false,
05-30 16:21:32.245  8756  8756 D StorageFile:         "szPUID":        "",
05-30 16:21:32.245  8756  8756 D StorageFile:         "szPUNAME":        "",
05-30 16:21:32.245  8756  8756 D StorageFile:         "szFilePath":        "/sdcard/RST3/aiwinn/jarvis/media/Video",
05-30 16:21:32.245  8756  8756 D StorageFile:         "szFileName":        "20190530_162132.mkv",
05-30 16:21:32.245  8756  8756 D StorageFile:         "szTriggerID":        "",
05-30 16:21:32.245  8756  8756 D StorageFile:         "iChannelIndex":        0,
05-30 16:21:32.245  8756  8756 D StorageFile:         "iFileDuration":        600,
05-30 16:21:32.245  8756  8756 D StorageFile:         "iFileType":        1,
05-30 16:21:32.245  8756  8756 D StorageFile:         "iFileStatus":        1,
05-30 16:21:32.245  8756  8756 D StorageFile:         "iRecordType":        1,
05-30 16:21:32.245  8756  8756 D StorageFile:         "szBeginTime":        "20190530_162132"
05-30 16:21:32.245  8756  8756 D StorageFile: }


reply

使用道具 report

2

主题

414

帖子

1188

积分

vipMem

Rank: 6Rank: 6

积分
1188
sofa
poston 2019-6-4 09:38 | authorOnly
只要有视频流输入,编解码器就会正常输出编码流,如果视频流输入不正常,自然就会导致阻塞
reply agree Against

使用道具 report

73

主题

319

帖子

1121

积分

vipMem

Rank: 6Rank: 6

积分
1121
bench
 Owner| poston 2019-6-4 15:22 | authorOnly
xuwei post on2019-6-4 09:38
只要有视频流输入,编解码器就会正常输出编码流,如果视频流输入不正常,自然就会导致阻塞

就是当时相机卡顿了,导致输入流慢,才会出现卡顿么?这个是偶现的,没找到复现的办法,如果输入流正常,编解码正常,就不会堵塞,其中一个不正常就会阻塞么?

我看log是从AMediaCodec_start success到get sps_pps success有了延迟,这段是在做什么?
reply agree Against

使用道具 report

2

主题

414

帖子

1188

积分

vipMem

Rank: 6Rank: 6

积分
1188
ground
poston 2019-6-4 20:31 | authorOnly
Aiwinn post on2019-6-4 15:22
就是当时相机卡顿了,导致输入流慢,才会出现卡顿么?这个是偶现的,没找到复现的办法,如果输入流正常, ...

因为没有图像输入,所以没有输出sps pps
reply agree Against

使用道具 report

creditRule

QQ|wireless surveillance

GMT+8, 2024-12-22 19:13 , Processed in 0.060543 second(s), 20 queries .

Powered by Discuz! X3.2

© 2001-2013 Comsenz Inc.

QuickReply backToTop BackToList