Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
Lima
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
62
Issues
62
List
Boards
Labels
Service Desk
Milestones
Jira
Jira
Merge Requests
4
Merge Requests
4
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
LimaGroup
Lima
Commits
d73d1fcb
Commit
d73d1fcb
authored
Nov 23, 2012
by
Roberto Arturo Homs-Regojo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Disable some part of the code for windows (HardwareSaving) which is not available yet (SEB)
parent
c935fcb6
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
25 additions
and
7 deletions
+25
-7
control/src/CtSaving.cpp
control/src/CtSaving.cpp
+5
-0
hardware/include/HwSavingCtrlObj.h
hardware/include/HwSavingCtrlObj.h
+4
-2
hardware/sip/HwSavingCtrlObj.sip
hardware/sip/HwSavingCtrlObj.sip
+2
-0
hardware/src/HwSavingCtrlObj.cpp
hardware/src/HwSavingCtrlObj.cpp
+14
-5
No files found.
control/src/CtSaving.cpp
View file @
d73d1fcb
...
...
@@ -414,6 +414,7 @@ CtSaving::CtSaving(CtControl &aCtrl) :
resetLastFrameNb
();
HwInterface
*
hw
=
aCtrl
.
hwInterface
();
#ifdef __linux__
m_has_hwsaving
=
hw
->
getHwCtrlObj
(
m_hwsaving
);
if
(
m_has_hwsaving
)
{
...
...
@@ -422,6 +423,10 @@ CtSaving::CtSaving(CtControl &aCtrl) :
}
else
m_new_frame_save_cbk
=
NULL
;
#else
m_has_hwsaving
=
false
;
m_new_frame_save_cbk
=
NULL
;
#endif
}
//@brief destructor
...
...
hardware/include/HwSavingCtrlObj.h
View file @
d73d1fcb
...
...
@@ -29,7 +29,6 @@
#include "HwFrameInfo.h"
#include "DirectoryEventUtils.h"
#ifdef __linux__
namespace
lima
{
class
LIMACORE_API
HwSavingCtrlObj
...
...
@@ -78,8 +77,10 @@ namespace lima
{
public:
virtual
~
Callback
()
{}
#ifdef __linux__
virtual
void
prepare
(
const
DirectoryEvent
::
Parameters
&
)
{};
virtual
bool
newFrameWritten
(
int
frame_id
)
=
0
;
#endif
};
void
registerCallback
(
Callback
*
cbk
);
...
...
@@ -107,9 +108,10 @@ namespace lima
class
DirectoryCallback
;
Callback
*
m_callback
;
#ifdef __linux__
DirectoryCallback
*
m_dir_cbk
;
DirectoryEvent
m_dir_event
;
#endif
};
}
#endif
#endif
hardware/sip/HwSavingCtrlObj.sip
View file @
d73d1fcb
...
...
@@ -62,8 +62,10 @@ public:
{
public:
virtual ~Callback();
%If (POSIX_PLATFORM)
virtual void prepare(const DirectoryEvent::Parameters &);
virtual bool newFrameWritten(int frame_id) = 0;
%End
};
void registerCallback(Callback *cbk);
...
...
hardware/src/HwSavingCtrlObj.cpp
View file @
d73d1fcb
...
...
@@ -28,7 +28,7 @@ using namespace lima;
const
char
*
HwSavingCtrlObj
::
RAW_FORMAT_STR
=
"RAW"
;
///< Raw format (no header)
const
char
*
HwSavingCtrlObj
::
EDF_FORMAT_STR
=
"EDF"
;
///< EDF format (Esrf Data Format)
const
char
*
HwSavingCtrlObj
::
CBF_FORMAT_STR
=
"CBF"
;
///< CBF format
#ifdef __linux__
class
HwSavingCtrlObj
::
DirectoryCallback
:
public
DirectoryEvent
::
Callback
{
public:
...
...
@@ -80,19 +80,24 @@ private:
int
m_start_file_number
;
std
::
deque
<
int
>
m_image_ids
;
};
#endif
HwSavingCtrlObj
::
HwSavingCtrlObj
(
int
capabilities
)
:
m_caps
(
capabilities
),
m_active
(
false
),
m_callback
(
NULL
),
m_dir_cbk
(
new
HwSavingCtrlObj
::
DirectoryCallback
(
*
this
)),
m_callback
(
NULL
)
#ifdef __linux__
,
m_dir_cbk
(
new
HwSavingCtrlObj
::
DirectoryCallback
(
*
this
)),
m_dir_event
(
true
,
*
m_dir_cbk
)
#endif
{
}
HwSavingCtrlObj
::~
HwSavingCtrlObj
()
{
#ifdef __linux__
delete
m_dir_cbk
;
#endif
}
void
HwSavingCtrlObj
::
setActive
(
bool
flag
)
...
...
@@ -170,7 +175,7 @@ void HwSavingCtrlObj::prepare()
if
(
m_active
)
{
_prepare
();
#ifdef __linux__
DirectoryEvent
::
Parameters
params
;
params
.
watch_path
=
m_directory
;
params
.
file_pattern
=
m_prefix
;
...
...
@@ -181,6 +186,7 @@ void HwSavingCtrlObj::prepare()
if
(
m_callback
)
m_callback
->
prepare
(
params
);
#endif
}
}
...
...
@@ -191,13 +197,16 @@ void HwSavingCtrlObj::start()
if
(
m_active
)
{
_start
();
#ifdef __linux__
m_dir_event
.
start
();
#endif
}
}
void
HwSavingCtrlObj
::
stop
()
{
#ifdef __linux__
m_dir_event
.
stop
();
#endif
}
int
HwSavingCtrlObj
::
getCapabilities
()
const
...
...
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