# gem.c File Reference

`#include "magick/studio.h"`
`#include "magick/color-private.h"`
`#include "magick/draw.h"`
`#include "magick/gem.h"`
`#include "magick/image.h"`
`#include "magick/image-private.h"`
`#include "magick/log.h"`
`#include "magick/memory_.h"`
`#include "magick/pixel-private.h"`
`#include "magick/quantum.h"`
`#include "magick/random_.h"`
`#include "magick/resize.h"`
`#include "magick/transform.h"`
`#include "magick/signature.h"`

## Functions

MagickExport void | ConvertHSBToRGB (const double hue, const double saturation, const double brightness, Quantum *red, Quantum *green, Quantum *blue)
static MagickRealType | ConvertHueToRGB (MagickRealType m1, MagickRealType m2, MagickRealType hue)
MagickExport void | ConvertHSLToRGB (const double hue, const double saturation, const double luminosity, Quantum *red, Quantum *green, Quantum *blue)
MagickExport void | ConvertHWBToRGB (const double hue, const double whiteness, const double blackness, Quantum *red, Quantum *green, Quantum *blue)
MagickExport void | ConvertRGBToHSB (const Quantum red, const Quantum green, const Quantum blue, double *hue, double *saturation, double *brightness)
static double | MagickMax (const double x, const double y)
static double | MagickMin (const double x, const double y)
MagickExport void | ConvertRGBToHSL (const Quantum red, const Quantum green, const Quantum blue, double *hue, double *saturation, double *luminosity)
MagickExport void | ConvertRGBToHWB (const Quantum red, const Quantum green, const Quantum blue, double *hue, double *whiteness, double *blackness)
MagickExport double | ExpandAffine (const AffineMatrix *affine)
MagickExport unsigned long | GetOptimalKernelWidth1D (const double radius, const double sigma)
MagickExport unsigned long | GetOptimalKernelWidth2D (const double radius, const double sigma)
MagickExport unsigned long | GetOptimalKernelWidth (const double radius, const double sigma)

## Function Documentation

MagickExport void ConvertHSBToRGB | ( | const double | hue,
|  | const double | saturation,
|  | const double | brightness,
|  | Quantum * | red,
|  | Quantum * | green,
|  | Quantum * | blue |
| ) |  |  |

MagickExport void ConvertHSLToRGB | ( | const double | hue,
|  | const double | saturation,
|  | const double | luminosity,
|  | Quantum * | red,
|  | Quantum * | green,
|  | Quantum * | blue |
| ) |  |  |

static MagickRealType ConvertHueToRGB | ( | MagickRealType | m1,
|  | MagickRealType | m2,
|  | MagickRealType | hue |
| ) |  |  | `[inline, static]`

MagickExport void ConvertHWBToRGB | ( | const double | hue,
|  | const double | whiteness,
|  | const double | blackness,
|  | Quantum * | red,
|  | Quantum * | green,
|  | Quantum * | blue |
| ) |  |  |

MagickExport void ConvertRGBToHSB | ( | const Quantum | red,
|  | const Quantum | green,
|  | const Quantum | blue,
|  | double * | hue,
|  | double * | saturation,
|  | double * | brightness |
| ) |  |  |

MagickExport void ConvertRGBToHSL | ( | const Quantum | red,
|  | const Quantum | green,
|  | const Quantum | blue,
|  | double * | hue,
|  | double * | saturation,
|  | double * | luminosity |
| ) |  |  |

MagickExport void ConvertRGBToHWB | ( | const Quantum | red,
|  | const Quantum | green,
|  | const Quantum | blue,
|  | double * | hue,
|  | double * | whiteness,
|  | double * | blackness |
| ) |  |  |

MagickExport double ExpandAffine | ( | const AffineMatrix * | affine | ) |

MagickExport unsigned long GetOptimalKernelWidth | ( | const double | radius,
|  | const double | sigma |
| ) |  |  |

MagickExport unsigned long GetOptimalKernelWidth1D | ( | const double | radius,
|  | const double | sigma |
| ) |  |  |

MagickExport unsigned long GetOptimalKernelWidth2D | ( | const double | radius,
|  | const double | sigma |
| ) |  |  |

static double MagickMax | ( | const double | x,
|  | const double | y |
| ) |  |  | `[inline, static]`

static double MagickMin | ( | const double | x,
|  | const double | y |
| ) |  |  | `[inline, static]`