Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKent Mein <mein@cs.umn.edu>2007-12-27 00:46:30 +0300
committerKent Mein <mein@cs.umn.edu>2007-12-27 00:46:30 +0300
commitae976e087a7110c6b25a0fee4f663185b5e4319d (patch)
tree836c8b93de2b6f726ce5ea64914e3945cd60a4ae /source/blender/imbuf/intern/dds/Image.cpp
parent8e84f64c3daa5cd2cafc7fd14d7d0fad472298cf (diff)
This is patch: [#7975] imbuf for DDS textures: improved read support and a few bugs fixed
Kent Notes From the author: The attached patch syncs the DDS code in Blender with the latest revision (324) of the nvidia texture tools. This fixes a few minor issues and adds support for a more types of DDS textures, in particular uncompressed textures that don't have the standard 16, 24, or 32 bits per pixel. Note: I have started using the nvidia texture tools convention for naming integer types (uint, uint16, uint8, uint64 etc.) because doing so makes it much easier to merge patches from upstream. Since the code is compiled separately from the rest of Blender, this likely does not pose a problem. However, if there turns out to be a good reason for avoiding those nvidia type names from upstream, I'd be happy to fix it. Regards, Amorilia
Diffstat (limited to 'source/blender/imbuf/intern/dds/Image.cpp')
-rw-r--r--source/blender/imbuf/intern/dds/Image.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/source/blender/imbuf/intern/dds/Image.cpp b/source/blender/imbuf/intern/dds/Image.cpp
index f3e6fa38955..d8be7857c3f 100644
--- a/source/blender/imbuf/intern/dds/Image.cpp
+++ b/source/blender/imbuf/intern/dds/Image.cpp
@@ -48,7 +48,7 @@ Image::~Image()
free();
}
-void Image::allocate(unsigned int w, unsigned int h)
+void Image::allocate(uint w, uint h)
{
free();
m_width = w;
@@ -63,17 +63,17 @@ void Image::free()
}
-unsigned int Image::width() const
+uint Image::width() const
{
return m_width;
}
-unsigned int Image::height() const
+uint Image::height() const
{
return m_height;
}
-const Color32 * Image::scanline(unsigned int h) const
+const Color32 * Image::scanline(uint h) const
{
if (h >= m_height) {
printf("DDS: scanline beyond dimensions of image");
@@ -82,7 +82,7 @@ const Color32 * Image::scanline(unsigned int h) const
return m_data + h * m_width;
}
-Color32 * Image::scanline(unsigned int h)
+Color32 * Image::scanline(uint h)
{
if (h >= m_height) {
printf("DDS: scanline beyond dimensions of image");
@@ -101,7 +101,7 @@ Color32 * Image::pixels()
return m_data;
}
-const Color32 & Image::pixel(unsigned int idx) const
+const Color32 & Image::pixel(uint idx) const
{
if (idx >= m_width * m_height) {
printf("DDS: pixel beyond dimensions of image");
@@ -110,7 +110,7 @@ const Color32 & Image::pixel(unsigned int idx) const
return m_data[idx];
}
-Color32 & Image::pixel(unsigned int idx)
+Color32 & Image::pixel(uint idx)
{
if (idx >= m_width * m_height) {
printf("DDS: pixel beyond dimensions of image");