| Description | Hierarchy | Fields | Methods | Properties |
type TNodeGeneralTexture = class(TVRMLNode)
Common texture node for all VRML versions.
![]() |
FTextureUsedFullUrl: string; |
![]() |
function LoadTextureImage(out CacheUsed: boolean): TImage; virtual; abstract; |
![]() |
constructor Create(const ANodeName: string; const AWWWBasePath: string); override; |
![]() |
destructor Destroy; override; |
![]() |
function TextureImage: TImage; |
![]() |
function IsTextureImage: boolean; |
![]() |
function TextureDescription: string; virtual; abstract; |
![]() |
function RepeatS: boolean; virtual; abstract; |
![]() |
function RepeatT: boolean; virtual; abstract; |
![]() |
property IsTextureLoaded: boolean
read FIsTextureLoaded write SetIsTextureLoaded; |
![]() |
property ImagesCache: TImagesCache read FImagesCache write FImagesCache; |
![]() |
property TextureUsedFullUrl: string read FTextureUsedFullUrl; |
![]() |
FTextureUsedFullUrl: string; |
![]() |
function LoadTextureImage(out CacheUsed: boolean): TImage; virtual; abstract; |
|
This loads actual image. It must return newly created TImage instance if texture could be loaded, or nil if no texture could be loaded. You do not care in this method about things like IsImageLoaded — this method should just always, unconditionally, make everything it can do to load texture. You can use VRMLNonFatalError inside, so we're prepared that this may even exit with exception (since VRMLNonFatalError can raise exception). You have to return TRGBImage or TAlphaImage here, see TextureImage docs. Set CacheUsed to Also, set FTextureUsedFullUrl here. | |
![]() |
constructor Create(const ANodeName: string; const AWWWBasePath: string); override; |
![]() |
destructor Destroy; override; |
![]() |
function TextureImage: TImage; |
|
Texture image, inline or loaded from URL. First call to Be sure to set ImagesCache before loading the texture. TODO: allow ImagesCache to be This is never IsTextureLoaded says whether the texture is already loaded. Since the texture will be loaded automatically, you're usually not interested in this property. You can read it to e.g. predict if next You can also set IsTextureLoaded. Setting to Note that separate IsTextureLoaded and IsTextureImage state means that if the texture loading will fail (e.g. "texture file foo.png does not exist"), it will be reported to VRMLNonFatalError only once, not at every
| |
![]() |
function IsTextureImage: boolean; |
![]() |
function RepeatS: boolean; virtual; abstract; |
![]() |
function RepeatT: boolean; virtual; abstract; |
![]() |
property IsTextureLoaded: boolean
read FIsTextureLoaded write SetIsTextureLoaded; |
![]() |
property ImagesCache: TImagesCache read FImagesCache write FImagesCache; |
![]() |
property TextureUsedFullUrl: string read FTextureUsedFullUrl; |
|
Once the image is loaded, this is set to the URL that was used to load this image, or '' if no URL was used. No URL was used may mean that no image was valid, or inlined image was used. This is always a full, expanded (i.e. not relative) URL. | |