diff options
author | gman@google.com <gman@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-08-06 04:53:24 +0000 |
---|---|---|
committer | gman@google.com <gman@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-08-06 04:53:24 +0000 |
commit | 132899b905b0f1794d7e82e28f9fe77ca6a08282 (patch) | |
tree | 47af391191ac78d3b4e02533f74e3575970cebcc /o3d/import | |
parent | 22e037073118aaf90549410b32d66885d39b78a9 (diff) | |
download | chromium_src-132899b905b0f1794d7e82e28f9fe77ca6a08282.zip chromium_src-132899b905b0f1794d7e82e28f9fe77ca6a08282.tar.gz chromium_src-132899b905b0f1794d7e82e28f9fe77ca6a08282.tar.bz2 |
A step in exposing Bitmap to JavaScript.
The plan is to make pack.createBitmapFromRawData
return an array of bitmaps.
1 bitmap if it's a standard 2d image
6 bitmaps if it's a cubemap
N bitmaps if it's a volume map.
The bitmaps will have a semantic so you can look at them and tell
they were from a volumemap, a cubemap or a 2d image.
On the way I'm attempting to clean up the code. Moving
stuff out of Bitmap the did not belong there and
Refactoring Bitmap so there are less If Format =
stuff.
Review URL: http://codereview.chromium.org/164034
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22583 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'o3d/import')
-rw-r--r-- | o3d/import/cross/collada.cc | 3 | ||||
-rw-r--r-- | o3d/import/cross/gz_compressor_test.cc | 1 | ||||
-rw-r--r-- | o3d/import/cross/gz_decompressor_test.cc | 1 | ||||
-rw-r--r-- | o3d/import/cross/precompile.h | 7 | ||||
-rw-r--r-- | o3d/import/cross/raw_data.h | 2 | ||||
-rw-r--r-- | o3d/import/cross/raw_data_test.cc | 1 | ||||
-rw-r--r-- | o3d/import/cross/tar_generator_test.cc | 1 | ||||
-rw-r--r-- | o3d/import/cross/tar_processor_test.cc | 1 | ||||
-rw-r--r-- | o3d/import/cross/targz_generator_test.cc | 1 | ||||
-rw-r--r-- | o3d/import/cross/targz_processor_test.cc | 1 |
10 files changed, 9 insertions, 10 deletions
diff --git a/o3d/import/cross/collada.cc b/o3d/import/cross/collada.cc index 0e88ae2..e04c32a 100644 --- a/o3d/import/cross/collada.cc +++ b/o3d/import/cross/collada.cc @@ -49,6 +49,7 @@ #include "core/cross/pack.h" #include "core/cross/param_operation.h" #include "core/cross/primitive.h" +#include "core/cross/sampler.h" #include "core/cross/skin.h" #include "core/cross/stream.h" #include "import/cross/collada.h" @@ -1686,7 +1687,7 @@ Texture* Collada::BuildTextureFromImage(FCDImage* image) { tex = Texture::Ref( pack_->CreateTextureFromFile(FilePathToUTF8(uri), file_path, - Bitmap::UNKNOWN, + image::UNKNOWN, options_.generate_mipmaps)); if (tex) { const fstring name(image->GetName()); diff --git a/o3d/import/cross/gz_compressor_test.cc b/o3d/import/cross/gz_compressor_test.cc index cd39499..3ca59d0 100644 --- a/o3d/import/cross/gz_compressor_test.cc +++ b/o3d/import/cross/gz_compressor_test.cc @@ -33,7 +33,6 @@ #include <sys/stat.h> #include <string> -#include "core/cross/client.h" #include "import/cross/memory_stream.h" #include "import/cross/memory_buffer.h" #include "import/cross/gz_decompressor.h" diff --git a/o3d/import/cross/gz_decompressor_test.cc b/o3d/import/cross/gz_decompressor_test.cc index ec79ad9..f2d1212 100644 --- a/o3d/import/cross/gz_decompressor_test.cc +++ b/o3d/import/cross/gz_decompressor_test.cc @@ -33,7 +33,6 @@ #include <sys/stat.h> #include <algorithm> -#include "core/cross/client.h" #include "import/cross/gz_decompressor.h" #include "import/cross/memory_buffer.h" #include "tests/common/win/testing_common.h" diff --git a/o3d/import/cross/precompile.h b/o3d/import/cross/precompile.h index e1daa2b..20671d6 100644 --- a/o3d/import/cross/precompile.h +++ b/o3d/import/cross/precompile.h @@ -42,6 +42,13 @@ #ifdef __cplusplus +#if defined(RENDERER_GL) +#include <GL/glew.h> +#if defined(OS_WIN) +#include <GL/wglew.h> +#endif +#endif // defined(RENDERER_GL) + #include <Cg/cg.h> #include <Cg/cgGL.h> #include <FCollada.h> diff --git a/o3d/import/cross/raw_data.h b/o3d/import/cross/raw_data.h index 1929b1a..092c800 100644 --- a/o3d/import/cross/raw_data.h +++ b/o3d/import/cross/raw_data.h @@ -46,8 +46,6 @@ #include "core/cross/param.h" #include "core/cross/types.h" -class FilePath; - namespace o3d { // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ diff --git a/o3d/import/cross/raw_data_test.cc b/o3d/import/cross/raw_data_test.cc index 4399cd9..b4c5f86 100644 --- a/o3d/import/cross/raw_data_test.cc +++ b/o3d/import/cross/raw_data_test.cc @@ -32,7 +32,6 @@ // Tests functionality of the RawData class -#include "core/cross/client.h" #include "tests/common/win/testing_common.h" #include "utils/cross/file_path_utils.h" #include "base/file_path.h" diff --git a/o3d/import/cross/tar_generator_test.cc b/o3d/import/cross/tar_generator_test.cc index 5fdec8a..1659e98 100644 --- a/o3d/import/cross/tar_generator_test.cc +++ b/o3d/import/cross/tar_generator_test.cc @@ -30,7 +30,6 @@ */ -#include "core/cross/client.h" #include "import/cross/memory_buffer.h" #include "import/cross/memory_stream.h" #include "import/cross/tar_generator.h" diff --git a/o3d/import/cross/tar_processor_test.cc b/o3d/import/cross/tar_processor_test.cc index 2e1f0bd..4da0f97 100644 --- a/o3d/import/cross/tar_processor_test.cc +++ b/o3d/import/cross/tar_processor_test.cc @@ -30,7 +30,6 @@ */ -#include "core/cross/client.h" #include "import/cross/targz_processor.h" #include "tests/common/win/testing_common.h" #include "tests/common/cross/test_utils.h" diff --git a/o3d/import/cross/targz_generator_test.cc b/o3d/import/cross/targz_generator_test.cc index 7911387..e3331f3 100644 --- a/o3d/import/cross/targz_generator_test.cc +++ b/o3d/import/cross/targz_generator_test.cc @@ -33,7 +33,6 @@ #include <string> #include "base/file_util.h" -#include "core/cross/client.h" #include "import/cross/memory_stream.h" #include "import/cross/targz_generator.h" #include "tests/common/cross/test_utils.h" diff --git a/o3d/import/cross/targz_processor_test.cc b/o3d/import/cross/targz_processor_test.cc index a351ec8..37d70a4 100644 --- a/o3d/import/cross/targz_processor_test.cc +++ b/o3d/import/cross/targz_processor_test.cc @@ -30,7 +30,6 @@ */ -#include "core/cross/client.h" #include "import/cross/targz_processor.h" #include "tests/common/win/testing_common.h" |