forked from micro-manager/micro-manager
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
DeviceInstance classes to manage loaded devices.
git-svn-id: https://valelab.ucsf.edu/svn/micromanager2/trunk@13408 d0ab736e-dc22-4aeb-8dc9-08def0aa14fd
- Loading branch information
mark
committed
May 15, 2014
1 parent
b82274f
commit 6c714ed
Showing
43 changed files
with
2,400 additions
and
507 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
// PROJECT: Micro-Manager | ||
// SUBSYSTEM: MMCore | ||
// | ||
// DESCRIPTION: Autofocus device instance wrapper | ||
// | ||
// COPYRIGHT: University of California, San Francisco, 2014, | ||
// All Rights reserved | ||
// | ||
// LICENSE: This file is distributed under the "Lesser GPL" (LGPL) license. | ||
// License text is included with the source distribution. | ||
// | ||
// This file is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty | ||
// of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | ||
// | ||
// IN NO EVENT SHALL THE COPYRIGHT OWNER OR | ||
// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, | ||
// INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES. | ||
// | ||
// AUTHOR: Mark Tsuchida | ||
|
||
#include "AutoFocusInstance.h" | ||
|
||
|
||
int AutoFocusInstance::SetContinuousFocusing(bool state) { return GetImpl()->SetContinuousFocusing(state); } | ||
int AutoFocusInstance::GetContinuousFocusing(bool& state) { return GetImpl()->GetContinuousFocusing(state); } | ||
bool AutoFocusInstance::IsContinuousFocusLocked() { return GetImpl()->IsContinuousFocusLocked(); } | ||
int AutoFocusInstance::FullFocus() { return GetImpl()->FullFocus(); } | ||
int AutoFocusInstance::IncrementalFocus() { return GetImpl()->IncrementalFocus(); } | ||
int AutoFocusInstance::GetLastFocusScore(double& score) { return GetImpl()->GetLastFocusScore(score); } | ||
int AutoFocusInstance::GetCurrentFocusScore(double& score) { return GetImpl()->GetCurrentFocusScore(score); } | ||
int AutoFocusInstance::AutoSetParameters() { return GetImpl()->AutoSetParameters(); } | ||
int AutoFocusInstance::GetOffset(double &offset) { return GetImpl()->GetOffset(offset); } | ||
int AutoFocusInstance::SetOffset(double offset) { return GetImpl()->SetOffset(offset); } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
// PROJECT: Micro-Manager | ||
// SUBSYSTEM: MMCore | ||
// | ||
// COPYRIGHT: University of California, San Francisco, 2014, | ||
// All Rights reserved | ||
// | ||
// LICENSE: This file is distributed under the "Lesser GPL" (LGPL) license. | ||
// License text is included with the source distribution. | ||
// | ||
// This file is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty | ||
// of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | ||
// | ||
// IN NO EVENT SHALL THE COPYRIGHT OWNER OR | ||
// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, | ||
// INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES. | ||
// | ||
// AUTHOR: Mark Tsuchida | ||
|
||
#pragma once | ||
|
||
#include "DeviceInstanceBase.h" | ||
|
||
|
||
class AutoFocusInstance : public DeviceInstanceBase<MM::AutoFocus> | ||
{ | ||
public: | ||
AutoFocusInstance(CMMCore* core, | ||
boost::shared_ptr<LoadedDeviceAdapter> adapter, | ||
const std::string& name, | ||
MM::Device* pDevice, | ||
DeleteDeviceFunction deleteFunction, | ||
const std::string& label) : | ||
DeviceInstanceBase(core, adapter, name, pDevice, deleteFunction, label) | ||
{} | ||
|
||
int SetContinuousFocusing(bool state); | ||
int GetContinuousFocusing(bool& state); | ||
bool IsContinuousFocusLocked(); | ||
int FullFocus(); | ||
int IncrementalFocus(); | ||
int GetLastFocusScore(double& score); | ||
int GetCurrentFocusScore(double& score); | ||
int AutoSetParameters(); | ||
int GetOffset(double &offset); | ||
int SetOffset(double offset); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
// PROJECT: Micro-Manager | ||
// SUBSYSTEM: MMCore | ||
// | ||
// DESCRIPTION: Camera device instance wrapper | ||
// | ||
// COPYRIGHT: University of California, San Francisco, 2014, | ||
// All Rights reserved | ||
// | ||
// LICENSE: This file is distributed under the "Lesser GPL" (LGPL) license. | ||
// License text is included with the source distribution. | ||
// | ||
// This file is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty | ||
// of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | ||
// | ||
// IN NO EVENT SHALL THE COPYRIGHT OWNER OR | ||
// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, | ||
// INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES. | ||
// | ||
// AUTHOR: Mark Tsuchida | ||
|
||
#include "CameraInstance.h" | ||
|
||
|
||
int CameraInstance::SnapImage() { return GetImpl()->SnapImage(); } | ||
const unsigned char* CameraInstance::GetImageBuffer() { return GetImpl()->GetImageBuffer(); } | ||
const unsigned char* CameraInstance::GetImageBuffer(unsigned channelNr) { return GetImpl()->GetImageBuffer(channelNr); } | ||
const unsigned int* CameraInstance::GetImageBufferAsRGB32() { return GetImpl()->GetImageBufferAsRGB32(); } | ||
unsigned CameraInstance::GetNumberOfComponents() const { return GetImpl()->GetNumberOfComponents(); } | ||
int CameraInstance::GetComponentName(unsigned component, char* name) { return GetImpl()->GetComponentName(component, name); } | ||
int unsigned CameraInstance::GetNumberOfChannels() const { return GetImpl()->GetNumberOfChannels(); } | ||
int CameraInstance::GetChannelName(unsigned channel, char* name) { return GetImpl()->GetChannelName(channel, name); } | ||
long CameraInstance::GetImageBufferSize()const { return GetImpl()->GetImageBufferSize(); } | ||
unsigned CameraInstance::GetImageWidth() const { return GetImpl()->GetImageWidth(); } | ||
unsigned CameraInstance::GetImageHeight() const { return GetImpl()->GetImageHeight(); } | ||
unsigned CameraInstance::GetImageBytesPerPixel() const { return GetImpl()->GetImageBytesPerPixel(); } | ||
unsigned CameraInstance::GetBitDepth() const { return GetImpl()->GetBitDepth(); } | ||
double CameraInstance::GetPixelSizeUm() const { return GetImpl()->GetPixelSizeUm(); } | ||
int CameraInstance::GetBinning() const { return GetImpl()->GetBinning(); } | ||
int CameraInstance::SetBinning(int binSize) { return GetImpl()->SetBinning(binSize); } | ||
void CameraInstance::SetExposure(double exp_ms) { return GetImpl()->SetExposure(exp_ms); } | ||
double CameraInstance::GetExposure() const { return GetImpl()->GetExposure(); } | ||
int CameraInstance::SetROI(unsigned x, unsigned y, unsigned xSize, unsigned ySize) { return GetImpl()->SetROI(x, y, xSize, ySize); } | ||
int CameraInstance::GetROI(unsigned& x, unsigned& y, unsigned& xSize, unsigned& ySize) { return GetImpl()->GetROI(x, y, xSize, ySize); } | ||
int CameraInstance::ClearROI() { return GetImpl()->ClearROI(); } | ||
int CameraInstance::StartSequenceAcquisition(long numImages, double interval_ms, bool stopOnOverflow) { return GetImpl()->StartSequenceAcquisition(numImages, interval_ms, stopOnOverflow); } | ||
int CameraInstance::StartSequenceAcquisition(double interval_ms) { return GetImpl()->StartSequenceAcquisition(interval_ms); } | ||
int CameraInstance::StopSequenceAcquisition() { return GetImpl()->StopSequenceAcquisition(); } | ||
int CameraInstance::PrepareSequenceAcqusition() { return GetImpl()->PrepareSequenceAcqusition(); } | ||
bool CameraInstance::IsCapturing() { return GetImpl()->IsCapturing(); } | ||
void CameraInstance::GetTags(char* serializedMetadata) { return GetImpl()->GetTags(serializedMetadata); } | ||
void CameraInstance::AddTag(const char* key, const char* deviceLabel, const char* value) { return GetImpl()->AddTag(key, deviceLabel, value); } | ||
void CameraInstance::RemoveTag(const char* key) { return GetImpl()->RemoveTag(key); } | ||
int CameraInstance::IsExposureSequenceable(bool& isSequenceable) const { return GetImpl()->IsExposureSequenceable(isSequenceable); } | ||
int CameraInstance::GetExposureSequenceMaxLength(long& nrEvents) const { return GetImpl()->GetExposureSequenceMaxLength(nrEvents); } | ||
int CameraInstance::StartExposureSequence() { return GetImpl()->StartExposureSequence(); } | ||
int CameraInstance::StopExposureSequence() { return GetImpl()->StopExposureSequence(); } | ||
int CameraInstance::ClearExposureSequence() { return GetImpl()->ClearExposureSequence(); } | ||
int CameraInstance::AddToExposureSequence(double exposureTime_ms) { return GetImpl()->AddToExposureSequence(exposureTime_ms); } | ||
int CameraInstance::SendExposureSequence() const { return GetImpl()->SendExposureSequence(); } |
Oops, something went wrong.