86 void SetPixel(UINT, UINT, Gdiplus::Color);
94 CMain(
const HWND hwnd);
113 void Jump(
float x,
float y);
114 const bool Origin(
float x,
float y)
const;
eDistribution
Distribution.
Interface for some helpful Windows-specific functions.
void ClearBitmap(Gdiplus::Color)
Clear bitmap to color.
CPerlinNoise2D * m_pPerlin
Pointer to Perlin noise generator.
HMENU m_hGenMenu
Handle to the Generate menu.
const std::wstring GetNoiseDescription() const
Get noise description.
void CreateMenus()
Create menus.
HMENU m_hSplineMenu
Handle to the Spline menu.
void DecreaseScale()
Decrease scale.
HMENU m_hDistMenu
Handle to the Distribution menu.
void GenerateNoiseBitmap()
Generate bitmap again with saved parameters.
void DrawGrid()
Draw grid to bitmap.
eNoise m_eNoise
Noise type.
bool m_bShowCoords
Show coordinates flag.
const float m_fMaxScale
Minimum scale.
const std::wstring GetFileName() const
Get noise file name.
const size_t m_nMaxOctaves
Maximum number of octaves of noise.
HMENU m_hFileMenu
Handle to the File menu.
void CreateBitmap(int w, int h)
Create bitmap.
void Randomize()
Randomize PRNG.
float m_fMax
Largest noise value in generated noise.
void Reset()
Reset number of octaves, scale, table size.
void UpdateMenus()
Update menus.
void DrawCoords()
Draw coordinates to bitmap.
bool SetDistribution(eDistribution)
Set probability distribution.
HMENU m_hHashMenu
Handle to the Hash menu.
void DecreaseTableSize()
Decrease table size.
float m_fAve
Average noise value in generated noise.
float m_fOriginX
X-coordinate of top.
CMain(const HWND hwnd)
Constructor.
void ToggleViewCoords()
Toggle View Coordinates flag.
float m_fOriginY
Y-coordinate of left.
const size_t m_nMinOctaves
Minimum number of octaves of noise.
void IncreaseTableSize()
Increase table size.
const size_t m_nDefOctaves
Default number of octaves of noise.
ULONG_PTR m_gdiplusToken
GDI+ token.
Gdiplus::Bitmap * GetBitmap() const
Get pointer to bitmap.
const float m_fMinScale
Minimum scale.
void SetHash(eHash)
Set hash function.
void DecreaseOctaves()
Decrease number of octaves.
void Jump()
Change origin coordinates.
HMENU m_hViewMenu
Handle to the View menu.
bool m_bShowGrid
Show grid flag.
void ToggleViewGrid()
Toggle View Grid flag.
HMENU m_hSetMenu
Handle to the Settings menu.
void SetSpline(eSpline)
Set spline function.
void IncreaseOctaves()
Increase number of octaves.
const bool Origin(float x, float y) const
Check origin coordinates.
Gdiplus::Bitmap * m_pBitmap
Pointer to a bitmap image.
void OnPaint()
Paint the client area of the window.
size_t m_nOctaves
Number of octaves of noise.
const float m_fDefScale
Default scale.
void SetPixel(UINT, UINT, float)
Set pixel grayscale from float.
void IncreaseScale()
Increase scale.
HWND m_hWnd
Window handle.
float m_fMin
Smallest noise value in generated noise.
HMENU m_hOctaveMenu
Handle to the Octave menu.
2D Perlin and Value noise generator.
Interface for the Perlin and Value noise generators.