|
@@ -665,7 +665,7 @@ class HaiKangController extends BaseController
|
|
$url = $this->artemis.'/api/video/v1/cameras/previewURLs';
|
|
$url = $this->artemis.'/api/video/v1/cameras/previewURLs';
|
|
$params['cameraIndexCode'] = $query->index_code;
|
|
$params['cameraIndexCode'] = $query->index_code;
|
|
$params['streamType'] = 0; //0主码流 1子码流 2第三码流
|
|
$params['streamType'] = 0; //0主码流 1子码流 2第三码流
|
|
- $params['protocol'] = 'hls';//rtmp
|
|
|
|
|
|
+ $params['protocol'] = 'ws';//rtmp
|
|
$params['transmode'] = 1; //0:UDP 1:TCP
|
|
$params['transmode'] = 1; //0:UDP 1:TCP
|
|
$params['expand'] = 'streamform=rtp';
|
|
$params['expand'] = 'streamform=rtp';
|
|
|
|
|
|
@@ -697,7 +697,7 @@ class HaiKangController extends BaseController
|
|
|
|
|
|
$ffmpeg_rtmp = $rtmp['data']['url'];
|
|
$ffmpeg_rtmp = $rtmp['data']['url'];
|
|
|
|
|
|
- $rtmp['data']['url'] = substr_replace($rtmp['data']['url'],env('HK_HLS'),0,22);
|
|
|
|
|
|
+ $rtmp['data']['url'] = substr_replace($rtmp['data']['url'],env('HK_HLS_JF'),0,20);
|
|
|
|
|
|
$result['data'] = [
|
|
$result['data'] = [
|
|
'camera_id' => Input::get('camera_id'),
|
|
'camera_id' => Input::get('camera_id'),
|
|
@@ -708,8 +708,8 @@ class HaiKangController extends BaseController
|
|
$cover_picture = CameraList::where('id', Input::get('camera_id'))->value('cover_picture');
|
|
$cover_picture = CameraList::where('id', Input::get('camera_id'))->value('cover_picture');
|
|
|
|
|
|
if (!$cover_picture) {
|
|
if (!$cover_picture) {
|
|
- register_shutdown_function(array($this, "getFirstPicture"),$path,$ffmpeg_rtmp);
|
|
|
|
-// $this->getPictureByHk($query);
|
|
|
|
|
|
+// register_shutdown_function(array($this, "getFirstPicture"),$path,$ffmpeg_rtmp);
|
|
|
|
+ $this->getPictureByHk($query);
|
|
}
|
|
}
|
|
|
|
|
|
return $result;
|
|
return $result;
|