Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
V
vimba
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
kr69sugu
vimba
Commits
97e1a879
Commit
97e1a879
authored
1 year ago
by
am0ebe
Browse files
Options
Downloads
Patches
Plain Diff
use asterix/glob in .pro file
parent
7c3aa759
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
obj/recorder-cmd.pro
+7
-18
7 additions, 18 deletions
obj/recorder-cmd.pro
src/core.cpp
+3
-10
3 additions, 10 deletions
src/core.cpp
src/core.h
+5
-5
5 additions, 5 deletions
src/core.h
src/frameobserver.cpp
+0
-1
0 additions, 1 deletion
src/frameobserver.cpp
with
15 additions
and
34 deletions
obj/recorder-cmd.pro
+
7
−
18
View file @
97e1a879
...
@@ -3,22 +3,11 @@ TEMPLATE = app
...
@@ -3,22 +3,11 @@ TEMPLATE = app
QT
+=
core
QT
+=
core
CONFIG
+=
c
++
20
warn_on
console
CONFIG
+=
c
++
20
warn_on
console
SOURCES
+=
\
SRC_DIR
=../
src
..
/
src
/
cmd
/
main
.
cpp
\
SOURCES
+=
$$
SRC_DIR
/
cmd
/*
.cpp \
..
/
src
/
cmd
/
console
.
cpp
\
$$SRC_DIR
/*
.cpp
..
/
src
/
core
.
cpp
\
HEADERS += $$SRC_DIR/cmd
/*
.h \
..
/
src
/
frameobserver
.
cpp
\
$$SRC_DIR
/*
.h
..
/
src
/
frameprocessor
.
cpp
\
..
/
src
/
camobserver
.
cpp
\
..
/
src
/
utils
.
cpp
HEADERS
+=
\
..
/
src
/
cmd
/
console
.
h
\
..
/
src
/
core
.
h
\
..
/
src
/
frameobserver
.
h
\
..
/
src
/
frameprocessor
.
h
\
..
/
src
/
camobserver
.
h
\
..
/
src
/
utils
.
h
DEFINES
*= QT_USE_QSTRINGBUILDER #converts + to % when building strings
DEFINES
*= QT_USE_QSTRINGBUILDER #converts + to % when building strings
...
@@ -40,7 +29,7 @@ QMAKE_CXXFLAGS += -Wno-deprecated-enum-enum-conversion # ignore opencv warnings.
...
@@ -40,7 +29,7 @@ QMAKE_CXXFLAGS += -Wno-deprecated-enum-enum-conversion # ignore opencv warnings.
# cp ../b/vimbax/api/lib/libVmb{C,CPP,ImageTransform}.so $${VIMBA_LIB_DIR}
# cp ../b/vimbax/api/lib/libVmb{C,CPP,ImageTransform}.so $${VIMBA_LIB_DIR}
TARGET = cmd
TARGET = cmd
DESTDIR = ../bin
DEST
_
DIR = ../bin
QMAKE_CLEAN += .cache/clangd/index
/*
.qmake.stash $${DESTDIR}
/*
jpg
QMAKE_CLEAN += .cache/clangd/index
/*
.qmake.stash $${DEST
_
DIR}
/*
jpg
#cant rm dir here, so added in sublime-project file
#cant rm dir here, so added in sublime-project file
This diff is collapsed.
Click to expand it.
src/core.cpp
+
3
−
10
View file @
97e1a879
...
@@ -29,10 +29,9 @@ Core::Core() :
...
@@ -29,10 +29,9 @@ Core::Core() :
// frames(FramePtrVector(QThread::idealThreadCount())),
// frames(FramePtrVector(QThread::idealThreadCount())),
pixelFormat
(
""
)
pixelFormat
(
""
)
{
{
QTimer
::
singleShot
(
0
,
this
,
SLOT
(
init
()));
//delayed init to allow connections to be established
QTimer
::
singleShot
(
0
,
this
,
SLOT
(
init
()));
//delayed init to allow connections to be established
-> print/error signals!
}
}
void
Core
::
init
()
void
Core
::
init
()
{
{
if
(
f
(
sys
.
Startup
(),
"init API"
)
)
if
(
f
(
sys
.
Startup
(),
"init API"
)
)
...
@@ -55,11 +54,6 @@ Core::~Core()
...
@@ -55,11 +54,6 @@ Core::~Core()
sys
.
Shutdown
();
sys
.
Shutdown
();
}
}
//2d
// need to update open / closed states.
//initially cams are closed, right? XXX how to find out?
//XXX track states
//VmbSystem::RegisterCameraListObserver
void
Core
::
listCams
()
void
Core
::
listCams
()
{
{
if
(
!
apiStarted
)
if
(
!
apiStarted
)
...
@@ -68,7 +62,7 @@ void Core::listCams()
...
@@ -68,7 +62,7 @@ void Core::listCams()
if
(
f
(
sys
.
GetCameras
(
cameras
),
"get cameras"
)
)
if
(
f
(
sys
.
GetCameras
(
cameras
),
"get cameras"
)
)
return
;
return
;
qDebug
().
noquote
()
<<
QString
(
"found %1 camera(s)"
).
arg
(
cameras
.
size
());
emitPrint
(
QString
(
"found %1 camera(s)"
).
arg
(
cameras
.
size
())
)
;
if
(
cameras
.
size
())
if
(
cameras
.
size
())
{
{
if
(
camIdx
==
-
1UL
||
camIdx
>=
cameras
.
size
()
)
if
(
camIdx
==
-
1UL
||
camIdx
>=
cameras
.
size
()
)
...
@@ -207,7 +201,6 @@ void Core::setCam(const int& newCamIdx)
...
@@ -207,7 +201,6 @@ void Core::setCam(const int& newCamIdx)
Put frame into the frame queue
Put frame into the frame queue
Start the acquisition engine ( curCam)
Start the acquisition engine ( curCam)
TODO use exceptions to not clutter error handling code here and catch em in main
TODO if( !curCam->isOpen() ) return; >> listener
TODO if( !curCam->isOpen() ) return; >> listener
2d get frameID
2d get frameID
*/
*/
...
@@ -237,7 +230,7 @@ void Core::startRecording()
...
@@ -237,7 +230,7 @@ void Core::startRecording()
g
(
curCam
->
StartCapture
(),
"start capture"
);
g
(
curCam
->
StartCapture
(),
"start capture"
);
for
(
auto
frame
:
frames
)
for
(
auto
&
frame
:
frames
)
g
(
curCam
->
QueueFrame
(
frame
),
"QueueFrame"
);
g
(
curCam
->
QueueFrame
(
frame
),
"QueueFrame"
);
g
(
curCam
->
GetFeatureByName
(
"AcquisitionStart"
,
pFeature
),
"get AcquisitionStart"
);
g
(
curCam
->
GetFeatureByName
(
"AcquisitionStart"
,
pFeature
),
"get AcquisitionStart"
);
...
...
This diff is collapsed.
Click to expand it.
src/core.h
+
5
−
5
View file @
97e1a879
...
@@ -7,12 +7,12 @@
...
@@ -7,12 +7,12 @@
#include
<VmbCPP/Interface.h>
#include
<VmbCPP/Interface.h>
#include
<VmbCPP/Camera.h>
#include
<VmbCPP/Camera.h>
namespace
VmbCPP
{
namespace
VmbCPP
{
class
VmbSystem
;
}
class
VmbSystem
;
using
VmbCPP
::
VmbSystem
;
}
using
VmbCPP
::
CameraPtr
;
using
VmbCPP
::
CameraPtr
;
using
VmbCPP
::
FeaturePtr
;
using
VmbCPP
::
FeaturePtr
;
using
VmbCPP
::
FramePtrVector
;
using
VmbCPP
::
FramePtrVector
;
using
VmbCPP
::
CameraPtrVector
;
class
Core
:
public
QObject
class
Core
:
public
QObject
{
{
...
@@ -50,8 +50,8 @@ class Core : public QObject
...
@@ -50,8 +50,8 @@ class Core : public QObject
void
getCamInfo
(
const
CameraPtr
&
);
void
getCamInfo
(
const
CameraPtr
&
);
bool
apiStarted
;
bool
apiStarted
;
VmbCPP
::
VmbSystem
&
sys
;
VmbSystem
&
sys
;
VmbCPP
::
CameraPtrVector
cameras
;
CameraPtrVector
cameras
;
ulong
camIdx
;
ulong
camIdx
;
CameraPtr
curCam
;
CameraPtr
curCam
;
...
...
This diff is collapsed.
Click to expand it.
src/frameobserver.cpp
+
0
−
1
View file @
97e1a879
...
@@ -4,7 +4,6 @@
...
@@ -4,7 +4,6 @@
#include
<VmbCPP/SharedPointerDefines.h>
#include
<VmbCPP/SharedPointerDefines.h>
#include
<VmbCPP/Camera.h>
#include
<VmbCPP/Camera.h>
// #include "qnamespace.h"
#include
<QDebug>
#include
<QDebug>
#include
<QThread>
#include
<QThread>
#include
<QObject>
#include
<QObject>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment