Oolite 1.91.0.7604-240417-a536cbe
Loading...
Searching...
No Matches
OOConcreteTexture.h
Go to the documentation of this file.
1/*
2
3OOConcreteTexture.h
4
5Standard implementation of OOTexture. This is an implementation detail, use
6OOTexture instead.
7
8
9Copyright (C) 2007-2013 Jens Ayton and contributors
10
11Permission is hereby granted, free of charge, to any person obtaining a copy
12of this software and associated documentation files (the "Software"), to deal
13in the Software without restriction, including without limitation the rights
14to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
15copies of the Software, and to permit persons to whom the Software is
16furnished to do so, subject to the following conditions:
17
18The above copyright notice and this permission notice shall be included in all
19copies or substantial portions of the Software.
20
21THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
26OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
27SOFTWARE.
28
29*/
30
31#import "OOTexture.h"
32
33
34#define OOTEXTURE_RELOADABLE 1
35
36
38{
39@private
40#if OOTEXTURE_RELOADABLE
41 NSString *_path;
42#endif
43 NSString *_key;
44 uint8_t _loaded: 1,
46#if GL_EXT_texture_rectangle
47 _isRectTexture: 1,
48#endif
49#if OO_TEXTURE_CUBE_MAP
50 _isCubeMap: 1,
51#endif
53 uint8_t _mipLevels;
54
56
57 void *_bytes;
59 uint32_t _width,
63
65 uint32_t _options;
66#if GL_EXT_texture_lod_bias
67 GLfloat _lodBias;
68#endif
69#if GL_EXT_texture_filter_anisotropic
70 float _anisotropy;
71#endif
72
73#ifndef NDEBUG
74 NSString *_name;
75#endif
76}
77
78- (id) initWithLoader:(OOTextureLoader *)loader
79 key:(NSString *)key
80 options:(uint32_t)options
81 anisotropy:(GLfloat)anisotropy
82 lodBias:(GLfloat)lodBias;
83
84- (id)initWithPath:(NSString *)path
85 key:(NSString *)key
86 options:(uint32_t)options
87 anisotropy:(float)anisotropy
88 lodBias:(GLfloat)lodBias;
89
90@end
OOPixMapFormat
Definition OOPixMap.h:39
OOTextureDataFormat _format
OOTextureLoader * _loader