iipsrv 1.2
iipsrv is an advanced high-performance feature-rich image server for web-based streamed viewing and zooming of ultra high-resolution images
Watermark Class Reference

Watermark class. More...

#include <Watermark.h>

Public Member Functions

 Watermark ()
 Constructor.
 
 Watermark (const std::string &file, float opacity, float probability)
 Constructor.
 
 ~Watermark ()
 Destructor.
 
void apply (void *data, unsigned int width, unsigned int height, unsigned int channels, unsigned int bpc)
 Apply the watermark to a data buffer.
 
std::string getImage ()
 Return watermark image path.
 
float getOpacity ()
 Return watermark opacity.
 
float getProbability ()
 Return watermark probability.
 
void init ()
 Initialize our watermark image.
 
bool isSet ()
 Determine whether a watermark has been specified.
 

Detailed Description

Watermark class.

Constructor & Destructor Documentation

◆ Watermark()

Watermark::Watermark ( const std::string &  file,
float  opacity,
float  probability 
)
inline

Constructor.

Parameters
fileimage file path
opacityopacity applied to watermark
probabilityprobability that watermark will be applied to a particular tile

Member Function Documentation

◆ apply()

void Watermark::apply ( void *  data,
unsigned int  width,
unsigned int  height,
unsigned int  channels,
unsigned int  bpc 
)

Apply the watermark to a data buffer.

Parameters
databuffer of image data
widthtile width
heighttile height
channelsnumber of channels
bpcbits per channel (8 or 16)

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