Panda3D
|
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University. More...
#include "pandabase.h"
#include "texture.h"
#include "config_gobj.h"
#include "config_putil.h"
#include "texturePool.h"
#include "textureContext.h"
#include "bamCache.h"
#include "bamCacheRecord.h"
#include "datagram.h"
#include "datagramIterator.h"
#include "bamReader.h"
#include "bamWriter.h"
#include "string_utils.h"
#include "preparedGraphicsObjects.h"
#include "pnmImage.h"
#include "pnmReader.h"
#include "pfmFile.h"
#include "pnmFileTypeRegistry.h"
#include "virtualFileSystem.h"
#include "datagramInputFile.h"
#include "datagramOutputFile.h"
#include "bam.h"
#include "zStream.h"
#include "indent.h"
#include "cmath.h"
#include "pStatTimer.h"
#include "pbitops.h"
#include "streamReader.h"
#include "texturePeeker.h"
#include "convert_srgb.h"
#include <stddef.h>
Go to the source code of this file.
Macros | |
#define | DDPF_ALPHAPIXELS 0x00000001 |
#define | DDPF_FOURCC 0x00000004 |
#define | DDPF_INDEXED 0x00000020 |
#define | DDPF_RGB 0x00000040 |
#define | DDS_MAGIC 0x20534444 |
#define | DDSCAPS2_CUBEMAP 0x00000200 |
#define | DDSCAPS2_CUBEMAP_NEGATIVEX 0x00000800 |
#define | DDSCAPS2_CUBEMAP_NEGATIVEY 0x00002000 |
#define | DDSCAPS2_CUBEMAP_NEGATIVEZ 0x00008000 |
#define | DDSCAPS2_CUBEMAP_POSITIVEX 0x00000400 |
#define | DDSCAPS2_CUBEMAP_POSITIVEY 0x00001000 |
#define | DDSCAPS2_CUBEMAP_POSITIVEZ 0x00004000 |
#define | DDSCAPS2_VOLUME 0x00200000 |
#define | DDSCAPS_COMPLEX 0x00000008 |
#define | DDSCAPS_MIPMAP 0x00400000 |
#define | DDSCAPS_TEXTURE 0x00001000 |
#define | DDSD_CAPS 0x00000001 |
#define | DDSD_DEPTH 0x00800000 |
#define | DDSD_HEIGHT 0x00000002 |
#define | DDSD_LINEARSIZE 0x00080000 |
#define | DDSD_MIPMAPCOUNT 0x00020000 |
#define | DDSD_PITCH 0x00000008 |
#define | DDSD_PIXELFORMAT 0x00001000 |
#define | DDSD_WIDTH 0x00000004 |
Functions | |
ostream & | operator<< (ostream &out, Texture::ComponentType ct) |
ostream & | operator<< (ostream &out, Texture::CompressionMode cm) |
ostream & | operator<< (ostream &out, Texture::Format f) |
ostream & | operator<< (ostream &out, Texture::QualityLevel tql) |
ostream & | operator<< (ostream &out, Texture::TextureType tt) |
istream & | operator>> (istream &in, Texture::QualityLevel &tql) |
PT (AsyncFuture) Texture | |
Indicates that the texture should be enqueued to be prepared in the indicated prepared_objects at the beginning of the next frame. | |
PT (Texture) Texture | |
Constructs a new Texture object from the txo file. | |
PT (TexturePeeker) Texture | |
Returns a TexturePeeker object that can be used to examine the individual texels stored within this Texture by (u, v) coordinate. | |
Variables | |
ConfigVariableEnum< Texture::QualityLevel > | texture_quality_level ("texture-quality-level", Texture::QL_normal, PRC_DESC("This specifies a global quality level for all textures. You " "may specify either fastest, normal, or best. This actually " "affects the meaning of Texture::set_quality_level(QL_default), " "so it may be overridden on a per-texture basis. This generally " "only has an effect when using the tinydisplay software renderer; " "it has little or no effect on normal, hardware-accelerated " "renderers. See Texture::set_quality_level().")) |
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
All rights reserved.
All use of this software is subject to the terms of the revised BSD license. You should have received a copy of this license along with this source code in a file named "LICENSE."
Definition in file texture.cxx.
#define DDPF_ALPHAPIXELS 0x00000001 |
Definition at line 93 of file texture.cxx.
#define DDPF_FOURCC 0x00000004 |
Definition at line 94 of file texture.cxx.
#define DDPF_INDEXED 0x00000020 |
Definition at line 95 of file texture.cxx.
#define DDPF_RGB 0x00000040 |
Definition at line 96 of file texture.cxx.
#define DDS_MAGIC 0x20534444 |
Definition at line 79 of file texture.cxx.
#define DDSCAPS2_CUBEMAP 0x00000200 |
Definition at line 104 of file texture.cxx.
#define DDSCAPS2_CUBEMAP_NEGATIVEX 0x00000800 |
Definition at line 106 of file texture.cxx.
#define DDSCAPS2_CUBEMAP_NEGATIVEY 0x00002000 |
Definition at line 108 of file texture.cxx.
#define DDSCAPS2_CUBEMAP_NEGATIVEZ 0x00008000 |
Definition at line 110 of file texture.cxx.
#define DDSCAPS2_CUBEMAP_POSITIVEX 0x00000400 |
Definition at line 105 of file texture.cxx.
#define DDSCAPS2_CUBEMAP_POSITIVEY 0x00001000 |
Definition at line 107 of file texture.cxx.
#define DDSCAPS2_CUBEMAP_POSITIVEZ 0x00004000 |
Definition at line 109 of file texture.cxx.
#define DDSCAPS2_VOLUME 0x00200000 |
Definition at line 111 of file texture.cxx.
#define DDSCAPS_COMPLEX 0x00000008 |
Definition at line 99 of file texture.cxx.
#define DDSCAPS_MIPMAP 0x00400000 |
Definition at line 101 of file texture.cxx.
#define DDSCAPS_TEXTURE 0x00001000 |
Definition at line 100 of file texture.cxx.
#define DDSD_CAPS 0x00000001 |
Definition at line 83 of file texture.cxx.
#define DDSD_DEPTH 0x00800000 |
Definition at line 90 of file texture.cxx.
#define DDSD_HEIGHT 0x00000002 |
Definition at line 84 of file texture.cxx.
#define DDSD_LINEARSIZE 0x00080000 |
Definition at line 89 of file texture.cxx.
#define DDSD_MIPMAPCOUNT 0x00020000 |
Definition at line 88 of file texture.cxx.
#define DDSD_PITCH 0x00000008 |
Definition at line 86 of file texture.cxx.
#define DDSD_PIXELFORMAT 0x00001000 |
Definition at line 87 of file texture.cxx.
#define DDSD_WIDTH 0x00000004 |
Definition at line 85 of file texture.cxx.
enum KTXCompressedFormat |
Definition at line 312 of file texture.cxx.
enum KTXFormat |
Definition at line 172 of file texture.cxx.
enum KTXType |
Definition at line 145 of file texture.cxx.
ostream & operator<< | ( | ostream & | out, |
Texture::ComponentType | ct ) |
Definition at line 10814 of file texture.cxx.
ostream & operator<< | ( | ostream & | out, |
Texture::CompressionMode | cm ) |
Definition at line 10830 of file texture.cxx.
ostream & operator<< | ( | ostream & | out, |
Texture::Format | f ) |
Definition at line 10822 of file texture.cxx.
ostream & operator<< | ( | ostream & | out, |
Texture::QualityLevel | tql ) |
Definition at line 10838 of file texture.cxx.
ostream & operator<< | ( | ostream & | out, |
Texture::TextureType | tt ) |
Definition at line 10806 of file texture.cxx.
istream & operator>> | ( | istream & | in, |
Texture::QualityLevel & | tql ) |
Definition at line 10847 of file texture.cxx.
PT | ( | AsyncFuture | ) |
Indicates that the texture should be enqueued to be prepared in the indicated prepared_objects at the beginning of the next frame.
This will ensure the texture is already loaded into texture memory if it is expected to be rendered soon.
Use this function instead of prepare_now() to preload textures from a user interface standpoint.
Definition at line 1434 of file texture.cxx.
PT | ( | Texture | ) |
Constructs a new Texture object from the txo file.
The internal implementation of operator =().
A factory function to make a new Texture, used to pass to the TexturePool.
This is similar to Texture::read_txo(), but it constructs and returns a new object, which allows it to return a subclass of Texture (for instance, a movie texture).
Pass a real filename if it is available, or empty string if it is not.
Assumes the lock is already held on both Textures.
Definition at line 859 of file texture.cxx.
References BamReader::init(), TypedObject::is_exact_type(), TypedObject::is_of_type(), DatagramInputFile::open(), DatagramInputFile::read_header(), BamReader::read_object(), and BamReader::resolve().
PT | ( | TexturePeeker | ) |
Returns a TexturePeeker object that can be used to examine the individual texels stored within this Texture by (u, v) coordinate.
If the texture has a ram image resident, that image is used. If it does not have a full ram image but does have a simple_ram_image resident, that image is used instead. If neither image is resident the full image is reloaded.
Returns NULL if the texture cannot find an image to load, or the texture format is incompatible.
Definition at line 1413 of file texture.cxx.