This repository has been archived by the owner on Dec 12, 2019. It is now read-only.
-
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.
Merge pull request #145 from Astroua/develop
Release 0.6 - Integration with CASA image analysis libraries
- Loading branch information
Showing
277 changed files
with
16,508 additions
and
2,351 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
/** | ||
* | ||
**/ | ||
|
||
|
||
#include "ConversionIntensityHook.h" | ||
|
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,72 @@ | ||
/** | ||
* Hook for converting intensity units. | ||
* | ||
**/ | ||
|
||
#pragma once | ||
|
||
#include "CartaLib/CartaLib.h" | ||
#include "CartaLib/IPlugin.h" | ||
|
||
namespace Carta | ||
{ | ||
namespace Lib | ||
{ | ||
namespace Image { | ||
class ImageInterface; | ||
} | ||
namespace Hooks | ||
{ | ||
class ConversionIntensityHook : public BaseHook | ||
{ | ||
CARTA_HOOK_BOILER1( ConversionIntensityHook ); | ||
|
||
public: | ||
|
||
typedef std::vector<double> ResultType; | ||
|
||
/** | ||
* @brief Params | ||
*/ | ||
struct Params { | ||
|
||
Params( std::shared_ptr<Image::ImageInterface> dataSource, | ||
const QString& oldUnit, const QString& newUnit, | ||
std::vector<double> inputXValues, std::vector<double> inputYValues, | ||
double maxYValue, const QString& maxUnit){ | ||
m_dataSource = dataSource; | ||
m_oldUnit = oldUnit; | ||
m_newUnit = newUnit; | ||
m_maxUnit = maxUnit; | ||
m_maxValueY = maxYValue; | ||
m_inputListX = inputXValues; | ||
m_inputListY = inputYValues; | ||
} | ||
|
||
std::shared_ptr<Image::ImageInterface> m_dataSource; | ||
std::vector<double> m_inputListX; | ||
std::vector<double> m_inputListY; | ||
QString m_newUnit; | ||
QString m_oldUnit; | ||
QString m_maxUnit; | ||
double m_maxValueY; | ||
|
||
}; | ||
|
||
/** | ||
* @brief PreRender | ||
* @param pptr | ||
* | ||
* @todo make hook constructors protected, so that only hook helper can create them | ||
*/ | ||
ConversionIntensityHook( Params * pptr ) : BaseHook( staticId ), paramsPtr( pptr ) | ||
{ | ||
CARTA_ASSERT( is < Me > () ); | ||
} | ||
|
||
ResultType result; | ||
Params * paramsPtr; | ||
}; | ||
} | ||
} | ||
} |
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,7 @@ | ||
/** | ||
* | ||
**/ | ||
|
||
|
||
#include "ConversionSpectralHook.h" | ||
|
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,64 @@ | ||
/** | ||
* Hook for converting intensity units. | ||
* | ||
**/ | ||
|
||
#pragma once | ||
|
||
#include "CartaLib/CartaLib.h" | ||
#include "CartaLib/IPlugin.h" | ||
|
||
namespace Carta | ||
{ | ||
namespace Lib | ||
{ | ||
namespace Image { | ||
class ImageInterface; | ||
} | ||
namespace Hooks | ||
{ | ||
class ConversionSpectralHook : public BaseHook | ||
{ | ||
CARTA_HOOK_BOILER1( ConversionSpectralHook ); | ||
|
||
public: | ||
|
||
typedef std::vector<double> ResultType; | ||
|
||
/** | ||
* @brief Params | ||
*/ | ||
struct Params { | ||
|
||
Params( std::shared_ptr<Image::ImageInterface> dataSource, | ||
QString oldUnit, QString newUnit, | ||
std::vector<double> inputValues ){ | ||
m_dataSource = dataSource; | ||
m_oldUnit = oldUnit; | ||
m_newUnit = newUnit; | ||
m_inputList = inputValues; | ||
} | ||
|
||
std::shared_ptr<Image::ImageInterface> m_dataSource; | ||
std::vector<double> m_inputList; | ||
QString m_newUnit; | ||
QString m_oldUnit; | ||
}; | ||
|
||
/** | ||
* @brief PreRender | ||
* @param pptr | ||
* | ||
* @todo make hook constructors protected, so that only hook helper can create them | ||
*/ | ||
ConversionSpectralHook( Params * pptr ) : BaseHook( staticId ), paramsPtr( pptr ) | ||
{ | ||
CARTA_ASSERT( is < Me > () ); | ||
} | ||
|
||
ResultType result; | ||
Params * paramsPtr; | ||
}; | ||
} | ||
} | ||
} |
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
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,7 @@ | ||
/** | ||
* | ||
**/ | ||
|
||
|
||
#include "ImageStatisticsHook.h" | ||
|
Oops, something went wrong.