26 #include <boost/utility.hpp>
27 #include <boost/tuple/tuple.hpp>
49 const std::uint16_t yResolution,
50 const std::string& pngOutFileName );
64 const std::uint8_t red,
65 const std::uint8_t green,
66 const std::uint8_t blue );
71 const std::uint16_t
getXRes(
void )
const;
76 const std::uint16_t
getYRes(
void )
const;
127 std::list<png::pngFactory::pixelType>
pxlLst;
void translatePixel(png::pngFactory::pixelType &p) const
This method maps a single pixel from the user specified coordinate plane to pixel space...
long double xTranslationFactor
This attribute holds the scalar used to translate caller specified x coordinates into the image coord...
long double xMin
This attribute holds the smallest x coordinate the caller has specified.
const std::uint16_t xRes
This attribute holds the X resolution of the PNG image.
std::tuple< long double, long double, std::uint8_t, std::uint8_t, std::uint8_t > pixelType
This type is used to define variables that hold single pixels.
::png_structp pngStructPtr
This attribute holds the libpng defined PNG structure used when generating the PNG image...
~pngFactory()
The class destructor.
void renderAllPixels(void)
This method renders all pixels.
std::list< png::pngFactory::pixelType > pxlLst
This attribute holds all caller specified pixels.
const std::string pFileName
This attribute holds the name of the file into which the final PNG image is to placed.
void updateMinMax(const png::pngFactory::pixelType &p)
This method is called to update the minimums and maximums, as tracked by this instance.
const std::uint16_t yRes
This attribute holds the Y resolution of the PNG image.
void writePngFile(void)
This method writes the PNG image out to disk.
const std::uint16_t getXRes(void) const
This method returns to the caller the horizontal resolution of the image.
void translateAllPixels(void)
This method maps all pixels from the user specified coordinate plane to pixel space.
long double yTranslationFactor
This attribute holds the scalar used to translate caller specified y coordinates into the image coord...
std::uint8_t * pngRowPtrType
This type is used to access rows in the PNG image.
This class provides an interface into libpng that is not completely insane (like libpng's native inte...
long double yMax
This attribute holds the largest y coordinate the caller has specified.
void findMinMax(void)
This method is called to determine the minimums and maximums, as tracked by this instance.
void deallocatePngImageSpace(void)
This method deallocates the PNG image space.
void addPixel(const long double x, const long double y, const std::uint8_t red, const std::uint8_t green, const std::uint8_t blue)
This method is called to add a pixel to the PNG image.
long double yMin
This attribute holds the smallest y coordinate the caller has specified.
const std::uint16_t getYRes(void) const
This method returns to the caller the vertical resolution of the image.
::png_infop pngInfoPtr
This attribute holds the libpng defined PNG info structure used when generating the PNG image...
long double xMax
This attribute holds the largest x coordinate the caller has specified.
png::pngFactory::pngRowPtrType * pngRowPointers
This attribute holds a row pointer used to access the PNG image.
void allocatePngImageSpace(void)
This method allocates space from the heap to hold the PNG image.