raylib-cpp
C++ object-oriented wrapper library for raylib.
Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members
raylib::Image Class Reference

Public Member Functions

 Image (const ::Font &font, const std::string &text, float fontSize, float spacing, ::Color tint={255, 255, 255, 255})
 
 Image (const ::Image &image)
 
 Image (const ::Texture2D &texture)
 
 Image (const std::string &fileName)
 
 Image (const std::string &fileName, int *frames)
 
 Image (const std::string &fileName, int width, int height, int format, int headerSize)
 
 Image (const std::string &fileType, const unsigned char *fileData, int dataSize)
 
 Image (int width, int height, ::Color color={255, 255, 255, 255})
 
 ~Image ()
 
Image & AlphaCrop (float threshold)
 Crop image depending on alpha value. More...
 
Image & AlphaMask (const ::Image &alphaMask)
 Apply alpha mask to image. More...
 
Image & AlphaPremultiply ()
 Premultiply alpha channel. More...
 
Image & ClearBackground (::Color color={0, 0, 0, 255})
 Clear image background with given color. More...
 
Image & ColorBrightness (int brightness)
 Modify image color: brightness. More...
 
Image & ColorContrast (float contrast)
 Modify image color: contrast. More...
 
Image & ColorGrayscale ()
 Modify image color: grayscale. More...
 
Image & ColorInvert ()
 Modify image color: invert. More...
 
Image & ColorReplace (::Color color, ::Color replace)
 Modify image color: replace color. More...
 
Image & ColorTint (::Color color={255, 255, 255, 255})
 Modify image color: tint. More...
 
inline ::Image Copy ()
 Create an image duplicate (useful for transformations) More...
 
Image & Crop (::Rectangle crop)
 Crop an image to area defined by a rectangle. More...
 
Image & Crop (::Vector2 size)
 Crop an image to a new given width and height based on a vector. More...
 
Image & Crop (int offsetX, int offsetY, int newWidth, int newHeight)
 Crop an image to area defined by a rectangle. More...
 
Image & Dither (int rBpp, int gBpp, int bBpp, int aBpp)
 Dither image data to 16bpp or lower (Floyd-Steinberg dithering) More...
 
Image & Draw (const ::Image &src, ::Rectangle srcRec, ::Rectangle dstRec, ::Color tint={255, 255, 255, 255})
 
Image & DrawCircle (::Vector2 center, int radius, ::Color color={255, 255, 255, 255})
 
Image & DrawCircle (int centerX, int centerY, int radius, ::Color color={255, 255, 255, 255})
 
Image & DrawLine (::Vector2 start, ::Vector2 end, ::Color color={255, 255, 255, 255})
 
Image & DrawLine (int startPosX, int startPosY, int endPosX, int endPosY, ::Color color={255, 255, 255, 255})
 
Image & DrawPixel (::Vector2 position, ::Color color={255, 255, 255, 255})
 
Image & DrawPixel (int posX, int posY, ::Color color={255, 255, 255, 255})
 Draw pixel within an image. More...
 
Image & DrawRectangle (::Rectangle rec, ::Color color={255, 255, 255, 255})
 
Image & DrawRectangle (int posX, int posY, int width, int height, ::Color color={255, 255, 255, 255})
 
Image & DrawRectangle (Vector2 position, Vector2 size, ::Color color={255, 255, 255, 255})
 
Image & DrawRectangleLines (::Rectangle rec, int thick, ::Color color={255, 255, 255, 255})
 
Image & DrawText (const ::Font &font, const std::string &text, ::Vector2 position, float fontSize, float spacing, ::Color tint={255, 255, 255, 255})
 
Image & DrawText (const std::string &text, ::Vector2 position, int fontSize, ::Color color={255, 255, 255, 255})
 
Image & DrawText (const std::string &text, int x, int y, int fontSize, ::Color color={255, 255, 255, 255})
 
bool Export (const std::string &fileName)
 Export image data to file, returns true on success. More...
 
bool ExportAsCode (const std::string &fileName)
 Export image as code file defining an array of bytes, returns true on success. More...
 
Image & FlipHorizontal ()
 Flip image horizontally. More...
 
Image & FlipVertical ()
 Flip image vertically. More...
 
Image & Format (int newFormat)
 Convert image data to desired format. More...
 
inline ::Image FromImage (::Rectangle rec)
 Create an image from another image piece. More...
 
Rectangle GetAlphaBorder (float threshold) const
 Get image alpha border rectangle. More...
 
void * GetData () const
 
int GetFormat () const
 
int GetHeight () const
 
int GetMipmaps () const
 
inline ::Vector2 GetSize ()
 Retrieve the width and height of the image. More...
 
int GetWidth () const
 
void Load (const std::string &fileName)
 Load image from file into CPU memory (RAM) More...
 
void LoadAnim (const std::string &fileName, int *frames)
 Load image sequence from file (frames appended to image.data). More...
 
inline ::Color * LoadColors ()
 Load color data from image as a Color array (RGBA - 32bit) More...
 
void LoadFromMemory (const std::string &fileType, const unsigned char *fileData, int dataSize)
 Load image from memory buffer, fileType refers to extension: i.e. More...
 
inline ::Color * LoadPalette (int maxPaletteSize, int *colorsCount)
 Load colors palette from image as a Color array (RGBA - 32bit) More...
 
void LoadRaw (const std::string &fileName, int width, int height, int format, int headerSize)
 Load image from RAW file data. More...
 
inline ::Texture2D LoadTexture ()
 Load texture from image data. More...
 
Image & Mipmaps ()
 Generate all mipmap levels for a provided image. More...
 
 operator::Texture2D ()
 Load texture from image data. More...
 
Image & operator= (const ::Image &image)
 
Image & Resize (int newWidth, int newHeight)
 Resize and image to new size. More...
 
Image & ResizeCanvas (int newWidth, int newHeight, int offsetX, int offsetY, ::Color color={255, 255, 255, 255})
 Resize canvas and fill with color. More...
 
Image & ResizeNN (int newWidth, int newHeight)
 Resize and image to new size using Nearest-Neighbor scaling algorithm. More...
 
Image & RotateCCW ()
 Rotate image counter-clockwise 90deg. More...
 
Image & RotateCW ()
 Rotate image clockwise 90deg. More...
 
void SetData (void *value)
 
void SetFormat (int value)
 
void SetHeight (int value)
 
void SetMipmaps (int value)
 
void SetWidth (int value)
 
Image & ToPOT (::Color fillColor)
 Convert image to POT (power-of-two) More...
 
void Unload ()
 Unload image from CPU memory (RAM) More...
 

Static Public Member Functions

::Image Cellular (int width, int height, int tileSize)
 Generate image: cellular algorithm. More...
 
::Image Checked (int width, int height, int checksX, int checksY, ::Color col1, ::Color col2)
 Generate image: checked. More...
 
::Image Color (int width, int height, ::Color color={255, 255, 255, 255})
 Generate image: plain color. More...
 
::Image GetScreenData ()
 Get pixel data from screen buffer and return an Image (screenshot) More...
 
::Image GradientH (int width, int height, ::Color left, ::Color right)
 Generate image: horizontal gradient. More...
 
::Image GradientRadial (int width, int height, float density, ::Color inner, ::Color outer)
 Generate image: radial gradient. More...
 
::Image GradientV (int width, int height, ::Color top, ::Color bottom)
 Generate image: vertical gradient. More...
 
::Image PerlinNoise (int width, int height, int offsetX, int offsetY, float scale=1.0f)
 Generate image: perlin noise. More...
 
::Image Text (const ::Font &font, const std::string &text, float fontSize, float spacing, ::Color tint={255, 255, 255, 255})
 
::Image Text (const std::string &text, int fontSize, ::Color color={255, 255, 255, 255})
 
::Image WhiteNoise (int width, int height, float factor)
 Generate image: white noise. More...
 

Protected Member Functions

void set (const ::Image &image)
 

Detailed Description

Definition at line 34 of file Image.hpp.

Constructor & Destructor Documentation

◆ Image() [1/8]

raylib::Image::Image ( const ::Image &  image)
inline

Definition at line 36 of file Image.hpp.

References set().

◆ Image() [2/8]

raylib::Image::Image ( const std::string &  fileName)
inline

Definition at line 40 of file Image.hpp.

References Load().

◆ Image() [3/8]

raylib::Image::Image ( const std::string &  fileName,
int  width,
int  height,
int  format,
int  headerSize 
)
inline

Definition at line 44 of file Image.hpp.

References LoadRaw().

◆ Image() [4/8]

raylib::Image::Image ( const std::string &  fileName,
int *  frames 
)
inline

Definition at line 48 of file Image.hpp.

References LoadAnim().

◆ Image() [5/8]

raylib::Image::Image ( const std::string &  fileType,
const unsigned char *  fileData,
int  dataSize 
)
inline

Definition at line 52 of file Image.hpp.

References LoadFromMemory().

◆ Image() [6/8]

raylib::Image::Image ( const ::Texture2D &  texture)
inline

Definition at line 56 of file Image.hpp.

References set().

◆ Image() [7/8]

raylib::Image::Image ( int  width,
int  height,
::Color  color = {255, 255, 255, 255} 
)
inline

Definition at line 60 of file Image.hpp.

◆ Image() [8/8]

raylib::Image::Image ( const ::Font &  font,
const std::string &  text,
float  fontSize,
float  spacing,
::Color  tint = {255, 255, 255, 255} 
)
inline

Definition at line 64 of file Image.hpp.

◆ ~Image()

raylib::Image::~Image ( )
inline

Definition at line 145 of file Image.hpp.

References Unload().

Member Function Documentation

◆ AlphaCrop()

Image& raylib::Image::AlphaCrop ( float  threshold)
inline

Crop image depending on alpha value.

Definition at line 264 of file Image.hpp.

◆ AlphaMask()

Image& raylib::Image::AlphaMask ( const ::Image &  alphaMask)
inline

Apply alpha mask to image.

Definition at line 256 of file Image.hpp.

◆ AlphaPremultiply()

Image& raylib::Image::AlphaPremultiply ( )
inline

Premultiply alpha channel.

Definition at line 272 of file Image.hpp.

◆ Cellular()

::Image raylib::Image::Cellular ( int  width,
int  height,
int  tileSize 
)
inlinestatic

Generate image: cellular algorithm.

Bigger tileSize means bigger cells

Definition at line 141 of file Image.hpp.

◆ Checked()

::Image raylib::Image::Checked ( int  width,
int  height,
int  checksX,
int  checksY,
::Color  col1,
::Color  col2 
)
inlinestatic

Generate image: checked.

Definition at line 118 of file Image.hpp.

◆ ClearBackground()

Image& raylib::Image::ClearBackground ( ::Color  color = {0, 0, 0, 255})
inline

Clear image background with given color.

Definition at line 443 of file Image.hpp.

◆ Color()

::Image raylib::Image::Color ( int  width,
int  height,
::Color  color = {255, 255, 255, 255} 
)
inlinestatic

Generate image: plain color.

Definition at line 89 of file Image.hpp.

◆ ColorBrightness()

Image& raylib::Image::ColorBrightness ( int  brightness)
inline

Modify image color: brightness.

Parameters
brightnessBrightness values between -255 and 255

Definition at line 418 of file Image.hpp.

◆ ColorContrast()

Image& raylib::Image::ColorContrast ( float  contrast)
inline

Modify image color: contrast.

Parameters
contrastContrast values between -100 and 100

Definition at line 408 of file Image.hpp.

◆ ColorGrayscale()

Image& raylib::Image::ColorGrayscale ( )
inline

Modify image color: grayscale.

Definition at line 398 of file Image.hpp.

◆ ColorInvert()

Image& raylib::Image::ColorInvert ( )
inline

Modify image color: invert.

Definition at line 390 of file Image.hpp.

◆ ColorReplace()

Image& raylib::Image::ColorReplace ( ::Color  color,
::Color  replace 
)
inline

Modify image color: replace color.

Definition at line 426 of file Image.hpp.

◆ ColorTint()

Image& raylib::Image::ColorTint ( ::Color  color = {255, 255, 255, 255})
inline

Modify image color: tint.

Definition at line 382 of file Image.hpp.

◆ Copy()

inline ::Image raylib::Image::Copy ( )
inline

Create an image duplicate (useful for transformations)

Definition at line 226 of file Image.hpp.

◆ Crop() [1/3]

Image& raylib::Image::Crop ( ::Rectangle  crop)
inline

Crop an image to area defined by a rectangle.

Definition at line 280 of file Image.hpp.

Referenced by Crop().

◆ Crop() [2/3]

Image& raylib::Image::Crop ( ::Vector2  size)
inline

Crop an image to a new given width and height based on a vector.

Definition at line 288 of file Image.hpp.

References Crop().

◆ Crop() [3/3]

Image& raylib::Image::Crop ( int  offsetX,
int  offsetY,
int  newWidth,
int  newHeight 
)
inline

Crop an image to area defined by a rectangle.

Definition at line 295 of file Image.hpp.

◆ Dither()

Image& raylib::Image::Dither ( int  rBpp,
int  gBpp,
int  bBpp,
int  aBpp 
)
inline

Dither image data to 16bpp or lower (Floyd-Steinberg dithering)

Definition at line 342 of file Image.hpp.

◆ Draw()

Image& raylib::Image::Draw ( const ::Image &  src,
::Rectangle  srcRec,
::Rectangle  dstRec,
::Color  tint = {255, 255, 255, 255} 
)
inline

Definition at line 507 of file Image.hpp.

◆ DrawCircle() [1/2]

Image& raylib::Image::DrawCircle ( ::Vector2  center,
int  radius,
::Color  color = {255, 255, 255, 255} 
)
inline

Definition at line 478 of file Image.hpp.

◆ DrawCircle() [2/2]

Image& raylib::Image::DrawCircle ( int  centerX,
int  centerY,
int  radius,
::Color  color = {255, 255, 255, 255} 
)
inline

Definition at line 472 of file Image.hpp.

◆ DrawLine() [1/2]

Image& raylib::Image::DrawLine ( ::Vector2  start,
::Vector2  end,
::Color  color = {255, 255, 255, 255} 
)
inline

Definition at line 467 of file Image.hpp.

◆ DrawLine() [2/2]

Image& raylib::Image::DrawLine ( int  startPosX,
int  startPosY,
int  endPosX,
int  endPosY,
::Color  color = {255, 255, 255, 255} 
)
inline

Definition at line 461 of file Image.hpp.

◆ DrawPixel() [1/2]

Image& raylib::Image::DrawPixel ( ::Vector2  position,
::Color  color = {255, 255, 255, 255} 
)
inline

Definition at line 456 of file Image.hpp.

◆ DrawPixel() [2/2]

Image& raylib::Image::DrawPixel ( int  posX,
int  posY,
::Color  color = {255, 255, 255, 255} 
)
inline

Draw pixel within an image.

Definition at line 451 of file Image.hpp.

◆ DrawRectangle() [1/3]

Image& raylib::Image::DrawRectangle ( ::Rectangle  rec,
::Color  color = {255, 255, 255, 255} 
)
inline

Definition at line 496 of file Image.hpp.

◆ DrawRectangle() [2/3]

Image& raylib::Image::DrawRectangle ( int  posX,
int  posY,
int  width,
int  height,
::Color  color = {255, 255, 255, 255} 
)
inline

Definition at line 484 of file Image.hpp.

◆ DrawRectangle() [3/3]

Image& raylib::Image::DrawRectangle ( Vector2  position,
Vector2  size,
::Color  color = {255, 255, 255, 255} 
)
inline

Definition at line 490 of file Image.hpp.

◆ DrawRectangleLines()

Image& raylib::Image::DrawRectangleLines ( ::Rectangle  rec,
int  thick,
::Color  color = {255, 255, 255, 255} 
)
inline

Definition at line 501 of file Image.hpp.

◆ DrawText() [1/3]

Image& raylib::Image::DrawText ( const ::Font &  font,
const std::string &  text,
::Vector2  position,
float  fontSize,
float  spacing,
::Color  tint = {255, 255, 255, 255} 
)
inline

Definition at line 530 of file Image.hpp.

◆ DrawText() [2/3]

Image& raylib::Image::DrawText ( const std::string &  text,
::Vector2  position,
int  fontSize,
::Color  color = {255, 255, 255, 255} 
)
inline

Definition at line 513 of file Image.hpp.

◆ DrawText() [3/3]

Image& raylib::Image::DrawText ( const std::string &  text,
int  x,
int  y,
int  fontSize,
::Color  color = {255, 255, 255, 255} 
)
inline

Definition at line 524 of file Image.hpp.

◆ Export()

bool raylib::Image::Export ( const std::string &  fileName)
inline

Export image data to file, returns true on success.

Definition at line 198 of file Image.hpp.

◆ ExportAsCode()

bool raylib::Image::ExportAsCode ( const std::string &  fileName)
inline

Export image as code file defining an array of bytes, returns true on success.

Definition at line 206 of file Image.hpp.

◆ FlipHorizontal()

Image& raylib::Image::FlipHorizontal ( )
inline

Flip image horizontally.

Definition at line 358 of file Image.hpp.

◆ FlipVertical()

Image& raylib::Image::FlipVertical ( )
inline

Flip image vertically.

Definition at line 350 of file Image.hpp.

◆ Format()

Image& raylib::Image::Format ( int  newFormat)
inline

Convert image data to desired format.

Definition at line 248 of file Image.hpp.

◆ FromImage()

inline ::Image raylib::Image::FromImage ( ::Rectangle  rec)
inline

Create an image from another image piece.

Definition at line 233 of file Image.hpp.

◆ GetAlphaBorder()

Rectangle raylib::Image::GetAlphaBorder ( float  threshold) const
inline

Get image alpha border rectangle.

Parameters
thresholdThreshold is defined as a percentatge: 0.0f -> 1.0f

Definition at line 436 of file Image.hpp.

◆ GetData()

void* raylib::Image::GetData ( ) const
inline

Definition at line 210 of file Image.hpp.

◆ GetFormat()

int raylib::Image::GetFormat ( ) const
inline

Definition at line 214 of file Image.hpp.

◆ GetHeight()

int raylib::Image::GetHeight ( ) const
inline

Definition at line 212 of file Image.hpp.

◆ GetMipmaps()

int raylib::Image::GetMipmaps ( ) const
inline

Definition at line 213 of file Image.hpp.

◆ GetScreenData()

::Image raylib::Image::GetScreenData ( )
inlinestatic

Get pixel data from screen buffer and return an Image (screenshot)

Definition at line 82 of file Image.hpp.

◆ GetSize()

inline ::Vector2 raylib::Image::GetSize ( )
inline

Retrieve the width and height of the image.

Definition at line 219 of file Image.hpp.

◆ GetWidth()

int raylib::Image::GetWidth ( ) const
inline

Definition at line 211 of file Image.hpp.

◆ GradientH()

::Image raylib::Image::GradientH ( int  width,
int  height,
::Color  left,
::Color  right 
)
inlinestatic

Generate image: horizontal gradient.

Definition at line 103 of file Image.hpp.

◆ GradientRadial()

::Image raylib::Image::GradientRadial ( int  width,
int  height,
float  density,
::Color  inner,
::Color  outer 
)
inlinestatic

Generate image: radial gradient.

Definition at line 110 of file Image.hpp.

◆ GradientV()

::Image raylib::Image::GradientV ( int  width,
int  height,
::Color  top,
::Color  bottom 
)
inlinestatic

Generate image: vertical gradient.

Definition at line 96 of file Image.hpp.

◆ Load()

void raylib::Image::Load ( const std::string &  fileName)
inline

Load image from file into CPU memory (RAM)

Definition at line 157 of file Image.hpp.

References raylib::LoadImage(), and set().

Referenced by Image().

◆ LoadAnim()

void raylib::Image::LoadAnim ( const std::string &  fileName,
int *  frames 
)
inline

Load image sequence from file (frames appended to image.data).

Definition at line 171 of file Image.hpp.

References raylib::LoadImageAnim(), and set().

Referenced by Image().

◆ LoadColors()

inline ::Color* raylib::Image::LoadColors ( )
inline

Load color data from image as a Color array (RGBA - 32bit)

Definition at line 539 of file Image.hpp.

◆ LoadFromMemory()

void raylib::Image::LoadFromMemory ( const std::string &  fileType,
const unsigned char *  fileData,
int  dataSize 
)
inline

Load image from memory buffer, fileType refers to extension: i.e.

"png".

Definition at line 178 of file Image.hpp.

References raylib::LoadImageFromMemory(), and set().

Referenced by Image().

◆ LoadPalette()

inline ::Color* raylib::Image::LoadPalette ( int  maxPaletteSize,
int *  colorsCount 
)
inline

Load colors palette from image as a Color array (RGBA - 32bit)

Definition at line 546 of file Image.hpp.

◆ LoadRaw()

void raylib::Image::LoadRaw ( const std::string &  fileName,
int  width,
int  height,
int  format,
int  headerSize 
)
inline

Load image from RAW file data.

Definition at line 164 of file Image.hpp.

References raylib::LoadImageRaw(), and set().

Referenced by Image().

◆ LoadTexture()

inline ::Texture2D raylib::Image::LoadTexture ( )
inline

Load texture from image data.

Definition at line 553 of file Image.hpp.

Referenced by operator::Texture2D().

◆ Mipmaps()

Image& raylib::Image::Mipmaps ( )
inline

Generate all mipmap levels for a provided image.

Definition at line 334 of file Image.hpp.

◆ operator::Texture2D()

raylib::Image::operator::Texture2D ( )
inline

Load texture from image data.

Definition at line 560 of file Image.hpp.

References LoadTexture().

◆ operator=()

Image& raylib::Image::operator= ( const ::Image &  image)
inline

Definition at line 149 of file Image.hpp.

References set().

◆ PerlinNoise()

::Image raylib::Image::PerlinNoise ( int  width,
int  height,
int  offsetX,
int  offsetY,
float  scale = 1.0f 
)
inlinestatic

Generate image: perlin noise.

Definition at line 133 of file Image.hpp.

◆ Resize()

Image& raylib::Image::Resize ( int  newWidth,
int  newHeight 
)
inline

Resize and image to new size.

Definition at line 309 of file Image.hpp.

◆ ResizeCanvas()

Image& raylib::Image::ResizeCanvas ( int  newWidth,
int  newHeight,
int  offsetX,
int  offsetY,
::Color  color = {255, 255, 255, 255} 
)
inline

Resize canvas and fill with color.

Definition at line 325 of file Image.hpp.

◆ ResizeNN()

Image& raylib::Image::ResizeNN ( int  newWidth,
int  newHeight 
)
inline

Resize and image to new size using Nearest-Neighbor scaling algorithm.

Definition at line 317 of file Image.hpp.

◆ RotateCCW()

Image& raylib::Image::RotateCCW ( )
inline

Rotate image counter-clockwise 90deg.

Definition at line 374 of file Image.hpp.

◆ RotateCW()

Image& raylib::Image::RotateCW ( )
inline

Rotate image clockwise 90deg.

Definition at line 366 of file Image.hpp.

◆ set()

void raylib::Image::set ( const ::Image &  image)
inlineprotected

Definition at line 565 of file Image.hpp.

Referenced by Image(), Load(), LoadAnim(), LoadFromMemory(), LoadRaw(), and operator=().

◆ SetData()

void raylib::Image::SetData ( void *  value)
inline

Definition at line 210 of file Image.hpp.

◆ SetFormat()

void raylib::Image::SetFormat ( int  value)
inline

Definition at line 214 of file Image.hpp.

◆ SetHeight()

void raylib::Image::SetHeight ( int  value)
inline

Definition at line 212 of file Image.hpp.

◆ SetMipmaps()

void raylib::Image::SetMipmaps ( int  value)
inline

Definition at line 213 of file Image.hpp.

◆ SetWidth()

void raylib::Image::SetWidth ( int  value)
inline

Definition at line 211 of file Image.hpp.

◆ Text() [1/2]

::Image raylib::Image::Text ( const ::Font &  font,
const std::string &  text,
float  fontSize,
float  spacing,
::Color  tint = {255, 255, 255, 255} 
)
inlinestatic

Definition at line 74 of file Image.hpp.

◆ Text() [2/2]

::Image raylib::Image::Text ( const std::string &  text,
int  fontSize,
::Color  color = {255, 255, 255, 255} 
)
inlinestatic

Definition at line 69 of file Image.hpp.

◆ ToPOT()

Image& raylib::Image::ToPOT ( ::Color  fillColor)
inline

Convert image to POT (power-of-two)

Definition at line 240 of file Image.hpp.

◆ Unload()

void raylib::Image::Unload ( )
inline

Unload image from CPU memory (RAM)

Definition at line 188 of file Image.hpp.

Referenced by ~Image().

◆ WhiteNoise()

::Image raylib::Image::WhiteNoise ( int  width,
int  height,
float  factor 
)
inlinestatic

Generate image: white noise.

Definition at line 126 of file Image.hpp.