IDSpeakIPL  v1.9.0
peak::ipl::EdgeEnhancement Class Referencefinal

Edge Enhancement for a given image. More...

#include <peak_ipl/algorithm/peak_ipl_edge_enhancement.hpp>

Public Member Functions

 EdgeEnhancement ()
 Constructor for a new EdgeEnhancement instance. More...
 
 ~EdgeEnhancement ()
 Destructor for the EdgeEnhancement instance. More...
 
 EdgeEnhancement (const EdgeEnhancement &other)
 Copy Constructor for a new EdgeEnhancement instance. More...
 
EdgeEnhancement & operator= (const EdgeEnhancement &other)
 Copy assigment for EdgeEnhancement instance. More...
 
 EdgeEnhancement (EdgeEnhancement &&other) noexcept
 Move constructor for EdgeEnhancement instance. More...
 
EdgeEnhancement & operator= (EdgeEnhancement &&other) noexcept
 Move assignment for EdgeEnhancement instance. More...
 
void ProcessInPlace (Image &image) const
 Process an image. More...
 
PEAK_IPL_NO_DISCARD Image Process (const Image &image) const
 Process an image. More...
 
PEAK_IPL_NO_DISCARD bool IsPixelFormatSupported (PixelFormatName pixelFormatName) const
 Check if the pixel format is supported. More...
 
void SetFactor (std::uint32_t factor)
 Set the edge enhancement factor. More...
 
PEAK_IPL_NO_DISCARD std::uint32_t Factor () const
 Get the edge enhancement factor. More...
 
PEAK_IPL_NO_DISCARD std::uint32_t DefaultFactor () const
 Get the default edge enhancement factor. More...
 
PEAK_IPL_NO_DISCARD peak::ipl::Range< std::uint32_t > Range () const
 Get the range for the edge enhancement factor. More...
 

Detailed Description

Edge Enhancement for a given image.

This class uses a software filter that emphasizes the edges in the image. The enhancement factor is configurable.

Constructor & Destructor Documentation

◆ EdgeEnhancement() [1/3]

peak::ipl::EdgeEnhancement::EdgeEnhancement ( )
inline

Constructor for a new EdgeEnhancement instance.

Creates a new EdgeEnhancement instance.

Since
1.7

◆ ~EdgeEnhancement()

peak::ipl::EdgeEnhancement::~EdgeEnhancement ( )
inline

Destructor for the EdgeEnhancement instance.

Destroys an EdgeEnhancement instance.

Since
1.7

◆ EdgeEnhancement() [2/3]

peak::ipl::EdgeEnhancement::EdgeEnhancement ( const EdgeEnhancement &  other)
inline

Copy Constructor for a new EdgeEnhancement instance.

Creates a new EdgeEnhancement instance.

Note
This only creates a shallow copy. See Shallow copy (since 1.8) for a detailed explanation.
Parameters
[in]otherThe other instance to acquire a reference for.
Since
1.7 Deleted
1.8 Implemented as shallow copy

◆ EdgeEnhancement() [3/3]

peak::ipl::EdgeEnhancement::EdgeEnhancement ( EdgeEnhancement &&  other)
inlinenoexcept

Move constructor for EdgeEnhancement instance.

Moves the instance from other to this. Afterwards other is invalid.

Parameters
[in]otherThe other instance to move.
Since
1.7

Member Function Documentation

◆ DefaultFactor()

uint32_t peak::ipl::EdgeEnhancement::DefaultFactor ( ) const
inline

Get the default edge enhancement factor.

Returns
the default edge enhancement factor
Exceptions
ExceptionAn internal error has occurred.
Since
1.7

◆ Factor()

uint32_t peak::ipl::EdgeEnhancement::Factor ( ) const
inline

Get the edge enhancement factor.

Returns
the current edge enhancement factor
Exceptions
ExceptionAn internal error has occurred.
Since
1.7

◆ IsPixelFormatSupported()

bool peak::ipl::EdgeEnhancement::IsPixelFormatSupported ( PixelFormatName  pixelFormatName) const
inline

Check if the pixel format is supported.

Note
Is currently only implemented for not packed and not raw pixel formats
Parameters
[in]pixelFormatNameThe PixelFormatName to check support for.
Returns
true if pixelformat is supported, else false
Exceptions
ExceptionAn internal error has occurred.
Since
1.7

◆ operator=() [1/2]

EdgeEnhancement & peak::ipl::EdgeEnhancement::operator= ( const EdgeEnhancement &  other)
inline

Copy assigment for EdgeEnhancement instance.

Acquires a reference from other to this instance. If this instance already has a reference, it will be destroyed.

Note
See Shallow copy (since 1.8) for a detailed explanation.
Parameters
[in]otherThe other instance to acquire a reference for.
Since
1.7 Deleted
1.8 Implemented as shallow copy

◆ operator=() [2/2]

EdgeEnhancement & peak::ipl::EdgeEnhancement::operator= ( EdgeEnhancement &&  other)
inlinenoexcept

Move assignment for EdgeEnhancement instance.

Moves the instance from other to this. Afterwards other is invalid.

Parameters
[in]otherThe other instance to move.
Since
1.7

◆ Process()

Image peak::ipl::EdgeEnhancement::Process ( const Image &  image) const
inline

Process an image.

To check if it is supported, call #EdgeEnhancement::IsPixelFormatSupported first This function causes a higher CPU load.

Parameters
[in]imageImage to process.
Returns
the sharpened image
Exceptions
InvalidPixelFormatpixel format isn't supported.
ExceptionAn internal error has occurred.
Since
1.7

◆ ProcessInPlace()

void peak::ipl::EdgeEnhancement::ProcessInPlace ( Image &  image) const
inline

Process an image.

To check if it is supported, call #EdgeEnhancement::IsPixelFormatSupported first This function causes a higher CPU load.

Parameters
[in]imageImage to process.
Exceptions
InvalidPixelFormatpixel format isn't supported.
ExceptionAn internal error has occurred.
Since
1.7

◆ Range()

Range< std::uint32_t > peak::ipl::EdgeEnhancement::Range ( ) const
inline

Get the range for the edge enhancement factor.

Returns
the range for the edge enhancement factor
Exceptions
ExceptionAn internal error has occurred.
Since
1.7

◆ SetFactor()

void peak::ipl::EdgeEnhancement::SetFactor ( std::uint32_t  factor)
inline

Set the edge enhancement factor.

Parameters
[in]factorThe factor to set.
Exceptions
ExceptionAn internal error has occurred.
Since
1.7

The documentation for this class was generated from the following file: