/* ========================================================================== * ÀÛ ¼º ÀÚ : À̼ø±Ô * ÀÛ ¼º ÀÏ : 2007.01.11 * ³» ¿ë : ³ôÀÌ¸Ê * ÁÖÀÇ»çÇ× : *===========================================================================*/ #pragma once class cFileLoader; /// ³ôÀÌ¸Ê class cHeightMap { public: cHeightMap(); cHeightMap( unsigned int width, unsigned int height ); /// Áö¿ò void Clear(); /// ·Îµù bool Load( const cString& pathName ); /// ÀúÀå bool Save( const cString& pathName ); /// ³ôÀ̰ª bool SetValue( unsigned int x, unsigned int y, float height ); bool GetValue( float* height, unsigned int x, unsigned int y ); /// ÁÖÀÇ: x¿Í y´Â [0, 1]»çÀÌÀÇ °ªÀ» °¡Á®¾ßÇÑ´Ù. bool GetValue( float* height , float x, float y ); /// ³Êºñ unsigned int GetWidth() const; /// ³ôÀÌ unsigned int GetHeight() const; protected: /// ³Êºñ unsigned int mWidth; /// ³ôÀÌ unsigned int mHeight; /// ¹öÆÛ typedef tArray cBuffer; cBuffer mBuffer; }; inline unsigned int cHeightMap::GetWidth() const { return mWidth; } inline unsigned int cHeightMap::GetHeight() const { return mHeight; }