Greatly improved Renderer

Separated Viewport from Scissor rect
Improved performances
Removed Lock/Unlock system from Shader/Texture class


Former-commit-id: f54bca6de58fe9d495d9192dc0d761f92594ee86
This commit is contained in:
Lynix
2013-05-03 02:58:35 +02:00
parent 76c19624d8
commit 4f3060a40d
15 changed files with 389 additions and 561 deletions

View File

@@ -34,7 +34,7 @@ class NAZARA_API NzTexture : public NzResource, NzNonCopyable
explicit NzTexture(const NzImage& image);
~NzTexture();
bool Create(nzImageType type, nzPixelFormat format, unsigned int width, unsigned int height, unsigned int depth = 1, nzUInt8 levelCount = 1, bool lock = false);
bool Create(nzImageType type, nzPixelFormat format, unsigned int width, unsigned int height, unsigned int depth = 1, nzUInt8 levelCount = 1);
void Destroy();
bool Download(NzImage* image) const;
@@ -72,8 +72,6 @@ class NAZARA_API NzTexture : public NzResource, NzNonCopyable
bool LoadFaceFromMemory(nzCubemapFace face, const void* data, std::size_t size, const NzImageParams& params = NzImageParams());
bool LoadFaceFromStream(nzCubemapFace face, NzInputStream& stream, const NzImageParams& params = NzImageParams());
bool Lock();
bool SetMipmapRange(nzUInt8 minLevel, nzUInt8 maxLevel);
bool Update(const NzImage& image, nzUInt8 level = 0);
@@ -87,8 +85,6 @@ class NAZARA_API NzTexture : public NzResource, NzNonCopyable
bool UpdateFace(nzCubemapFace face, const nzUInt8* pixels, unsigned int srcWidth = 0, unsigned int srcHeight = 0, nzUInt8 level = 0);
bool UpdateFace(nzCubemapFace face, const nzUInt8* pixels, const NzRectui& rect, unsigned int srcWidth = 0, unsigned int srcHeight = 0, nzUInt8 level = 0);
void Unlock();
// Fonctions OpenGL
bool Bind() const;
unsigned int GetOpenGLID() const;