Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gamera_videos_no_ui
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
liusq
gamera_videos_no_ui
Commits
22f4b088
Commit
22f4b088
authored
Sep 03, 2024
by
“liusq”
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复ping命令进程生命周期问题01
parent
6c388318
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
37 additions
and
30 deletions
+37
-30
CameraHandle.cpp
+8
-8
FaceReconitionHandle.cpp
+10
-10
VidesData.h
+12
-5
mainwindow.cpp
+7
-7
No files found.
CameraHandle.cpp
View file @
22f4b088
...
@@ -143,7 +143,7 @@ int XNetSDK_MediaCallBack(XSDK_HANDLE hMedia, int nDataType, int nDataLen, int n
...
@@ -143,7 +143,7 @@ int XNetSDK_MediaCallBack(XSDK_HANDLE hMedia, int nDataType, int nDataLen, int n
if
(
EXCMD_DOWNLOAD_DATA
==
nDataType
)
if
(
EXCMD_DOWNLOAD_DATA
==
nDataType
)
{
{
q
Debug
()
<<
"EXCMD_DOWNLOAD_DATA"
<<
nDataType
;
q
Info
()
<<
"EXCMD_DOWNLOAD_DATA"
<<
nDataType
;
/*if (g_hRecordDownload > 0 && g_hRecordDownload == hMedia)
/*if (g_hRecordDownload > 0 && g_hRecordDownload == hMedia)
{
{
...
@@ -197,9 +197,9 @@ int XNetSDK_MediaCallBack(XSDK_HANDLE hMedia, int nDataType, int nDataLen, int n
...
@@ -197,9 +197,9 @@ int XNetSDK_MediaCallBack(XSDK_HANDLE hMedia, int nDataType, int nDataLen, int n
// 等待 ffmpeg 进程结束
// 等待 ffmpeg 进程结束
if
(
ffmpegProcess
.
waitForFinished
(
20000
))
{
if
(
ffmpegProcess
.
waitForFinished
(
20000
))
{
//QFile::remove(dName);
//QFile::remove(dName);
q
Debug
()
<<
"ffmpeg process finished successfully."
;
q
Info
()
<<
"ffmpeg process finished successfully."
;
}
else
{
}
else
{
q
Debug
()
<<
"Error: ffmpeg process did not finish."
;
q
Info
()
<<
"Error: ffmpeg process did not finish."
;
}
}
// 销毁 QProcess 对象
// 销毁 QProcess 对象
...
@@ -354,7 +354,7 @@ void CameraHandle::sdkDownloadFileByTime(XSDK_HANDLE hDevice,int id,
...
@@ -354,7 +354,7 @@ void CameraHandle::sdkDownloadFileByTime(XSDK_HANDLE hDevice,int id,
//param.result = sdkInitCallback; // 结果回调(必填)
//param.result = sdkInitCallback; // 结果回调(必填)
SMsgReceiver
sms
(
nullptr
,
XNetSDK_MediaCallBack
,
this
);
SMsgReceiver
sms
(
nullptr
,
XNetSDK_MediaCallBack
,
this
);
param
.
result
=
sms
;
param
.
result
=
sms
;
q
Debug
()
<<
"XSDK_MediaRecordDownload hDevice:"
<<
this
->
hDevice
;
q
Info
()
<<
"XSDK_MediaRecordDownload hDevice:"
<<
this
->
hDevice
;
this
->
mediaHandle
=
XSDK_MediaRecordDownload
(
this
->
hDevice
,
&
param
,
0
,
4000
);
this
->
mediaHandle
=
XSDK_MediaRecordDownload
(
this
->
hDevice
,
&
param
,
0
,
4000
);
if
(
this
->
mediaHandle
<
0
)
if
(
this
->
mediaHandle
<
0
)
...
@@ -390,7 +390,7 @@ int CameraHandle::callbackFunction(XSDK_HANDLE hObject, QString &szString) {
...
@@ -390,7 +390,7 @@ int CameraHandle::callbackFunction(XSDK_HANDLE hObject, QString &szString) {
}
}
else
else
{
{
q
Debug
()
<<
"OnDevAlarmCallback[Dev:"
<<
hObject
<<
"][Event:"
<<
szString
<<
"]"
;
q
Info
()
<<
"OnDevAlarmCallback[Dev:"
<<
hObject
<<
"][Event:"
<<
szString
<<
"]"
;
}
}
cv
::
Mat
image
;
cv
::
Mat
image
;
MediaFaceImage
*
mediaFaceImage
=
MediaFaceImage
::
getInstance
();
MediaFaceImage
*
mediaFaceImage
=
MediaFaceImage
::
getInstance
();
...
@@ -429,7 +429,7 @@ void CameraHandle::sdkDevSnapSyn(XSDK_HANDLE hDevice, int nChannel){
...
@@ -429,7 +429,7 @@ void CameraHandle::sdkDevSnapSyn(XSDK_HANDLE hDevice, int nChannel){
int
ret
=
mediaFaceImage
->
FaceImageCallBack
(
hDevice
,
nChannel
,
image
);
int
ret
=
mediaFaceImage
->
FaceImageCallBack
(
hDevice
,
nChannel
,
image
);
if
(
ret
<
0
)
{
if
(
ret
<
0
)
{
offlineCount
++
;
// 累加计数器
offlineCount
++
;
// 累加计数器
q
Debug
()
<<
"offlineCount: "
<<
loginParam
->
sDevId
<<
offlineCount
;
q
Info
()
<<
"offlineCount: "
<<
loginParam
->
sDevId
<<
offlineCount
;
if
(
offlineCount
>=
3
)
{
// 判断是否连续3次返回0
if
(
offlineCount
>=
3
)
{
// 判断是否连续3次返回0
qInfo
()
<<
"设备离线"
;
qInfo
()
<<
"设备离线"
;
...
@@ -954,7 +954,7 @@ void CameraHandle::printWifi(XSDK_HANDLE hDevice,XSDK_CFG::NetWork_Wifi &cfg){
...
@@ -954,7 +954,7 @@ void CameraHandle::printWifi(XSDK_HANDLE hDevice,XSDK_CFG::NetWork_Wifi &cfg){
// 获取并解析配置
// 获取并解析配置
int
nResult
=
XSDK_DevGetSysConfigSyn
(
hDevice
,
JK_NetWork_Wifi
,
szOutBuffer
,
&
nInOutSize
,
3000
,
EXCMD_CONFIG_GET
);
int
nResult
=
XSDK_DevGetSysConfigSyn
(
hDevice
,
JK_NetWork_Wifi
,
szOutBuffer
,
&
nInOutSize
,
3000
,
EXCMD_CONFIG_GET
);
q
Debug
()
<<
szOutBuffer
;
q
Info
()
<<
szOutBuffer
;
if
(
nResult
>=
0
)
{
if
(
nResult
>=
0
)
{
cfg
.
Parse
(
szOutBuffer
);
cfg
.
Parse
(
szOutBuffer
);
...
@@ -1009,7 +1009,7 @@ void CameraHandle::sdkDevSystemTimeZoneSyn(QString &time){
...
@@ -1009,7 +1009,7 @@ void CameraHandle::sdkDevSystemTimeZoneSyn(QString &time){
//录像设置
//录像设置
void
CameraHandle
::
sdkRecordCfg
(
const
char
*
recordJson
){
void
CameraHandle
::
sdkRecordCfg
(
const
char
*
recordJson
){
q
Debug
()
<<
recordJson
;
q
Info
()
<<
recordJson
;
char
szOutBuffer
[
512
]
=
{
0
};
char
szOutBuffer
[
512
]
=
{
0
};
int
nLen
=
sizeof
(
szOutBuffer
);;
int
nLen
=
sizeof
(
szOutBuffer
);;
int
res
=
XSDK_DevSetSysConfigSyn
(
hDevice
,
JK_Record
,
recordJson
,
strlen
(
recordJson
),
szOutBuffer
,
&
nLen
,
3000
,
EXCMD_CONFIG_SET
);
int
res
=
XSDK_DevSetSysConfigSyn
(
hDevice
,
JK_Record
,
recordJson
,
strlen
(
recordJson
),
szOutBuffer
,
&
nLen
,
3000
,
EXCMD_CONFIG_SET
);
...
...
FaceReconitionHandle.cpp
View file @
22f4b088
...
@@ -37,7 +37,7 @@ cv::Mat FaceReconitionHandle::loadImage(const QString &path) {
...
@@ -37,7 +37,7 @@ cv::Mat FaceReconitionHandle::loadImage(const QString &path) {
std
::
string
stdPath
=
path
.
toStdString
();
std
::
string
stdPath
=
path
.
toStdString
();
cv
::
Mat
image
=
cv
::
imread
(
stdPath
,
cv
::
IMREAD_COLOR
);
cv
::
Mat
image
=
cv
::
imread
(
stdPath
,
cv
::
IMREAD_COLOR
);
if
(
!
image
.
empty
())
{
if
(
!
image
.
empty
())
{
q
Debug
()
<<
"图像以OpenCV成功加载。"
;
q
Info
()
<<
"图像以OpenCV成功加载。"
;
return
image
;
return
image
;
}
}
...
@@ -151,7 +151,7 @@ void FaceReconitionHandle::featureRemove(){
...
@@ -151,7 +151,7 @@ void FaceReconitionHandle::featureRemove(){
if
(
customIds
.
size
()
>
0
){
if
(
customIds
.
size
()
>
0
){
for
(
auto
customId
:
customIds
){
for
(
auto
customId
:
customIds
){
HResult
ret
=
HF_FeaturesGroupFeatureRemove
(
ctxHandle
,
customId
);
HResult
ret
=
HF_FeaturesGroupFeatureRemove
(
ctxHandle
,
customId
);
q
Debug
()
<<
"ret:featureRemove "
<<
ret
;
q
Info
()
<<
"ret:featureRemove "
<<
ret
;
}
}
setImageChanged
(
false
);
setImageChanged
(
false
);
}
}
...
@@ -180,10 +180,10 @@ cv::Mat FaceReconitionHandle::loadImageFromByteStream(const QString& filePath) {
...
@@ -180,10 +180,10 @@ cv::Mat FaceReconitionHandle::loadImageFromByteStream(const QString& filePath) {
}
}
return
mat
;
return
mat
;
}
catch
(
const
CImgException
&
e
)
{
}
catch
(
const
CImgException
&
e
)
{
q
Debug
()
<<
"CImg Error: "
<<
e
.
what
();
q
Info
()
<<
"CImg Error: "
<<
e
.
what
();
return
cv
::
Mat
();;
return
cv
::
Mat
();;
}
catch
(
const
cv
::
Exception
&
e
)
{
}
catch
(
const
cv
::
Exception
&
e
)
{
q
Debug
()
<<
"OpenCV Error: "
<<
e
.
what
();
q
Info
()
<<
"OpenCV Error: "
<<
e
.
what
();
return
cv
::
Mat
();
;
return
cv
::
Mat
();
;
}
}
...
@@ -218,7 +218,7 @@ void FaceReconitionHandle::doesItExistEmployee(const cv::Mat &source,std::list<v
...
@@ -218,7 +218,7 @@ void FaceReconitionHandle::doesItExistEmployee(const cv::Mat &source,std::list<v
HF_FaceContextRunFaceTrack
(
ctxHandle
,
imageSteamHandle
,
&
multipleFaceData
);
HF_FaceContextRunFaceTrack
(
ctxHandle
,
imageSteamHandle
,
&
multipleFaceData
);
if
(
multipleFaceData
.
detectedNum
<=
0
)
{
if
(
multipleFaceData
.
detectedNum
<=
0
)
{
q
Debug
()
<<
QString
(
"search 未检测到人脸"
);
q
Info
()
<<
QString
(
"search 未检测到人脸"
);
return
;
return
;
}
}
...
@@ -227,11 +227,11 @@ void FaceReconitionHandle::doesItExistEmployee(const cv::Mat &source,std::list<v
...
@@ -227,11 +227,11 @@ void FaceReconitionHandle::doesItExistEmployee(const cv::Mat &source,std::list<v
HInt32
featureNum
;
HInt32
featureNum
;
HF_GetFeatureLength
(
ctxHandle
,
&
featureNum
);
HF_GetFeatureLength
(
ctxHandle
,
&
featureNum
);
for
(
int
j
=
0
;
j
<
multipleFaceData
.
detectedNum
;
++
j
){
for
(
int
j
=
0
;
j
<
multipleFaceData
.
detectedNum
;
++
j
){
q
Debug
()
<<
QString
(
"doesItExistEmployee==>面部索引: %1"
).
arg
(
j
);
q
Info
()
<<
QString
(
"doesItExistEmployee==>面部索引: %1"
).
arg
(
j
);
std
::
vector
<
float
>
newfeature
(
featureNum
,
0.0
f
);
std
::
vector
<
float
>
newfeature
(
featureNum
,
0.0
f
);
ret
=
HF_FaceFeatureExtractCpy
(
ctxHandle
,
imageSteamHandle
,
multipleFaceData
.
tokens
[
j
],
newfeature
.
data
());
ret
=
HF_FaceFeatureExtractCpy
(
ctxHandle
,
imageSteamHandle
,
multipleFaceData
.
tokens
[
j
],
newfeature
.
data
());
if
(
ret
!=
HSUCCEED
)
{
if
(
ret
!=
HSUCCEED
)
{
q
Debug
()
<<
QString
(
"特征提取出错: %1"
).
arg
(
ret
);
q
Info
()
<<
QString
(
"特征提取出错: %1"
).
arg
(
ret
);
HF_ReleaseImageStream
(
imageSteamHandle
);
HF_ReleaseImageStream
(
imageSteamHandle
);
return
;
return
;
}
}
...
@@ -252,9 +252,9 @@ void FaceReconitionHandle::doesItExistEmployee(const cv::Mat &source,std::list<v
...
@@ -252,9 +252,9 @@ void FaceReconitionHandle::doesItExistEmployee(const cv::Mat &source,std::list<v
return
;
return
;
}
}
q
Debug
()
<<
QString
(
"搜索置信度: %1"
).
arg
(
confidence
);
q
Info
()
<<
QString
(
"搜索置信度: %1"
).
arg
(
confidence
);
q
Debug
()
<<
QString
(
"匹配到的tag: %1"
).
arg
(
searchIdentity
.
tag
);
q
Info
()
<<
QString
(
"匹配到的tag: %1"
).
arg
(
searchIdentity
.
tag
);
q
Debug
()
<<
QString
(
"匹配到的customId: %1"
).
arg
(
searchIdentity
.
customId
);
q
Info
()
<<
QString
(
"匹配到的customId: %1"
).
arg
(
searchIdentity
.
customId
);
// Face Pipeline
// Face Pipeline
//printf("人脸特征数量: %d", faceNum);
//printf("人脸特征数量: %d", faceNum);
if
(
confidence
>
configConfidence
)
{
if
(
confidence
>
configConfidence
)
{
...
...
VidesData.h
View file @
22f4b088
...
@@ -391,7 +391,7 @@ inline QString getDefaultGateway() {
...
@@ -391,7 +391,7 @@ inline QString getDefaultGateway() {
return
gateway
;
return
gateway
;
}
}
inline
bool
pingAddress
(
const
QString
&
address
)
{
bool
pingAddress
(
const
QString
&
address
)
{
QProcess
process
;
QProcess
process
;
QString
program
=
"ping"
;
QString
program
=
"ping"
;
QStringList
arguments
;
QStringList
arguments
;
...
@@ -407,21 +407,28 @@ inline bool pingAddress(const QString &address) {
...
@@ -407,21 +407,28 @@ inline bool pingAddress(const QString &address) {
return
false
;
return
false
;
}
}
if
(
!
process
.
waitForFinished
(
1000
))
{
// 使用较长的超时值,确保进程有足够时间完成
if
(
!
process
.
waitForFinished
(
3000
))
{
process
.
kill
();
// 如果超时,强制终止进程
return
false
;
return
false
;
}
}
QString
output
(
process
.
readAllStandardOutput
());
QString
output
(
process
.
readAllStandardOutput
());
// 此处可以使用更复杂的逻辑来解析 Ping 输出
// 简单的 Ping 成功检查逻辑
#ifdef Q_OS_WIN
return
output
.
contains
(
"TTL="
);
#else
return
output
.
contains
(
"1 packets transmitted, 1 received"
);
return
output
.
contains
(
"1 packets transmitted, 1 received"
);
#endif
}
}
inline
int
GetCpuIdByAsm_arm
(
char
*
cpu_id
)
inline
int
GetCpuIdByAsm_arm
(
char
*
cpu_id
)
{
{
FILE
*
fp
=
fopen
(
"/proc/cpuinfo"
,
"r"
);
FILE
*
fp
=
fopen
(
"/proc/cpuinfo"
,
"r"
);
if
(
nullptr
==
fp
)
if
(
nullptr
==
fp
)
{
{
q
Debug
()
<<
"failed to open cpuinfo"
;
q
Info
()
<<
"failed to open cpuinfo"
;
return
-
1
;
return
-
1
;
}
}
...
@@ -457,7 +464,7 @@ inline int GetCpuIdByAsm_arm(char* cpu_id)
...
@@ -457,7 +464,7 @@ inline int GetCpuIdByAsm_arm(char* cpu_id)
inline
QString
getCpuSerialNumber
()
{
inline
QString
getCpuSerialNumber
()
{
QFile
file
(
"/proc/cpuinfo"
);
QFile
file
(
"/proc/cpuinfo"
);
if
(
!
file
.
open
(
QIODevice
::
ReadOnly
|
QIODevice
::
Text
))
{
if
(
!
file
.
open
(
QIODevice
::
ReadOnly
|
QIODevice
::
Text
))
{
q
Debug
()
<<
"无法打开 /proc/cpuinfo 文件"
;
q
Info
()
<<
"无法打开 /proc/cpuinfo 文件"
;
return
QString
();
return
QString
();
}
}
QTextStream
in
(
&
file
);
QTextStream
in
(
&
file
);
...
...
mainwindow.cpp
View file @
22f4b088
...
@@ -124,7 +124,7 @@ MainWindow::MainWindow()
...
@@ -124,7 +124,7 @@ MainWindow::MainWindow()
if
(
!
server
.
listen
(
QHostAddress
::
Any
,
port
))
{
if
(
!
server
.
listen
(
QHostAddress
::
Any
,
port
))
{
qInfo
()
<<
"Error: Unable to start the server on port 12345"
;
qInfo
()
<<
"Error: Unable to start the server on port 12345"
;
}
else
{
}
else
{
q
Debug
()
<<
"Server started, listening on port 12345"
;
q
Info
()
<<
"Server started, listening on port 12345"
;
}
}
config
.
mqttConfig
.
clientId
=
serialNumber
;
config
.
mqttConfig
.
clientId
=
serialNumber
;
...
@@ -253,7 +253,7 @@ void MainWindow::handleMatNewConnection(){
...
@@ -253,7 +253,7 @@ void MainWindow::handleMatNewConnection(){
QRegExp
urlRegEx
(
"GET /cameras/([^/]+)/current_image HTTP"
);
QRegExp
urlRegEx
(
"GET /cameras/([^/]+)/current_image HTTP"
);
if
(
urlRegEx
.
indexIn
(
request
)
!=
-
1
)
{
if
(
urlRegEx
.
indexIn
(
request
)
!=
-
1
)
{
QString
sn
=
urlRegEx
.
cap
(
1
);
QString
sn
=
urlRegEx
.
cap
(
1
);
q
Debug
()
<<
"Requested Camera SN: "
<<
sn
;
q
Info
()
<<
"Requested Camera SN: "
<<
sn
;
bool
foundCamera
=
false
;
bool
foundCamera
=
false
;
for
(
auto
it
=
faceDetectionParkingPushs
.
begin
();
it
!=
faceDetectionParkingPushs
.
end
();
++
it
)
{
for
(
auto
it
=
faceDetectionParkingPushs
.
begin
();
it
!=
faceDetectionParkingPushs
.
end
();
++
it
)
{
QString
currentSn
=
it
->
second
->
getSSn
();
QString
currentSn
=
it
->
second
->
getSSn
();
...
@@ -307,7 +307,7 @@ void MainWindow::removeImageFiles(QString id){
...
@@ -307,7 +307,7 @@ void MainWindow::removeImageFiles(QString id){
QString
value
=
localIt
->
second
;
QString
value
=
localIt
->
second
;
QFile
file
(
value
);
QFile
file
(
value
);
if
(
!
file
.
open
(
QIODevice
::
WriteOnly
))
{
if
(
!
file
.
open
(
QIODevice
::
WriteOnly
))
{
q
Debug
()
<<
"removeImageFiles open fail"
<<
value
;
q
Info
()
<<
"removeImageFiles open fail"
<<
value
;
}
else
{
}
else
{
file
.
remove
();
file
.
remove
();
}
}
...
@@ -370,7 +370,7 @@ void MainWindow::updateLocalFace(const QString &httpurl) {
...
@@ -370,7 +370,7 @@ void MainWindow::updateLocalFace(const QString &httpurl) {
if
(
localIt
!=
localImageMap
.
end
())
{
if
(
localIt
!=
localImageMap
.
end
())
{
QFile
file
(
localIt
->
second
);
QFile
file
(
localIt
->
second
);
if
(
!
file
.
open
(
QIODevice
::
WriteOnly
))
{
if
(
!
file
.
open
(
QIODevice
::
WriteOnly
))
{
q
Debug
()
<<
"open fail"
<<
localIt
->
second
;
q
Info
()
<<
"open fail"
<<
localIt
->
second
;
}
else
{
}
else
{
file
.
remove
();
file
.
remove
();
qSetting
->
beginGroup
(
"localImageMap"
);
qSetting
->
beginGroup
(
"localImageMap"
);
...
@@ -716,14 +716,14 @@ void MainWindow::initEncodeToString(QString &enCodeJson) {
...
@@ -716,14 +716,14 @@ void MainWindow::initEncodeToString(QString &enCodeJson) {
}
}
bool
MainWindow
::
iniWorkSpVMn
(
vides_data
::
responseGb28181
*
gb28181
,
QString
&
workSpWMn
,
QString
&
sn
){
bool
MainWindow
::
iniWorkSpVMn
(
vides_data
::
responseGb28181
*
gb28181
,
QString
&
workSpWMn
,
QString
&
sn
){
q
Debug
()
<<
"iniWorkSpVMn=="
<<
sn
;
q
Info
()
<<
"iniWorkSpVMn=="
<<
sn
;
QString
jsonfile
=
QCoreApplication
::
applicationDirPath
()
+
"/camera_config.json"
;
QString
jsonfile
=
QCoreApplication
::
applicationDirPath
()
+
"/camera_config.json"
;
bool
isEqual
=
true
;
bool
isEqual
=
true
;
// 读取 JSON 配置文件
// 读取 JSON 配置文件
QFile
file
(
jsonfile
);
QFile
file
(
jsonfile
);
if
(
!
file
.
open
(
QIODevice
::
ReadOnly
))
{
if
(
!
file
.
open
(
QIODevice
::
ReadOnly
))
{
q
Debug
()
<<
"Failed to open the camera_config.json"
;
q
Info
()
<<
"Failed to open the camera_config.json"
;
return
isEqual
;
return
isEqual
;
}
}
QJsonObject
toJsonObject
;
QJsonObject
toJsonObject
;
...
@@ -975,7 +975,7 @@ void MainWindow::initCameras(vides_data::cameraParameters ¶meter,vides_data:
...
@@ -975,7 +975,7 @@ void MainWindow::initCameras(vides_data::cameraParameters ¶meter,vides_data:
CameraHandle
*
cameraHandle
=
new
CameraHandle
(
parameter
.
sDevId
,
parameter
.
httpUrl
,
parameter
.
sSn
,
parameter
.
channel
,
image_save
,
heightReference
,
devConfig
);
CameraHandle
*
cameraHandle
=
new
CameraHandle
(
parameter
.
sDevId
,
parameter
.
httpUrl
,
parameter
.
sSn
,
parameter
.
channel
,
image_save
,
heightReference
,
devConfig
);
int
sdk_handle
=
cameraHandle
->
sdkDevLoginSyn
(
parameter
.
sDevId
,
parameter
.
nDevPort
,
parameter
.
sUserName
,
parameter
.
sPassword
,
3000
);
int
sdk_handle
=
cameraHandle
->
sdkDevLoginSyn
(
parameter
.
sDevId
,
parameter
.
nDevPort
,
parameter
.
sUserName
,
parameter
.
sPassword
,
3000
);
q
Debug
()
<<
"句柄为2:"
<<
sdk_handle
;
q
Info
()
<<
"句柄为2:"
<<
sdk_handle
;
if
(
sdk_handle
<=
0
){
if
(
sdk_handle
<=
0
){
qInfo
()
<<
"登录失败"
;
qInfo
()
<<
"登录失败"
;
return
;
return
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment