Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Pages
platform
Rendering
AsyncTexturing
HttpAsyncTexture.h
1
// Copyright eeGeo Ltd (2012-2014), All Rights Reserved
2
3
#pragma once
4
5
#include "Types.h"
6
#include "IAsyncTexture.h"
7
#include "RefcountedAsyncTexture.h"
8
#include "GLHelpers.h"
9
#include "Web.h"
10
#include "AsyncTexturing.h"
11
#include <string>
12
#include "Rendering.h"
13
14
namespace
Eegeo
15
{
16
namespace
Rendering
17
{
18
namespace
AsyncTexturing
19
{
20
class
HttpAsyncTexture
:
protected
Eegeo::NonCopyable
,
public
RefcountedAsyncTexture
<HttpAsyncTexture>
21
{
22
public
:
23
HttpAsyncTexture
(
HttpAsyncTextureLoader
& asyncTextureLoader,
24
const
std::string& textureUrl,
25
IAsyncTexture
& initialTexture,
26
IAsyncTextureObserver
* pObserver,
27
ITextureFactory
& textureFactory,
28
bool
generateMipMaps=
false
,
29
bool
tryToUpdateIfModified=
false
);
30
31
32
void
DestroyTexture();
33
const
std::string GetUrl()
const
;
34
const
Helpers::GLHelpers::TextureInfo
& GetTextureInfo()
const
;
35
bool
HasMipMaps()
const
{
return
m_generateMipMaps; }
36
bool
IsLoaded()
const
;
37
bool
IsComplete()
const
;
38
bool
IsTryToUpdateIfModified()
const
;
39
40
void
SetWebLoadRequest(
Eegeo::Web::IWebLoadRequest
& webLoadRequest);
41
void
ClearWebLoadRequest();
42
void
SetLoadedTexture(
Eegeo::Helpers::GLHelpers::TextureInfo
& textureInfoToSet);
43
44
private
:
45
~
HttpAsyncTexture
();
46
47
HttpAsyncTextureLoader
& m_asyncTextureLoader;
48
std::string m_url;
49
IAsyncTexture
* m_texture;
50
IAsyncTextureObserver
* m_pObserver;
51
bool
m_isLoaded;
52
bool
m_isComplete;
53
bool
m_tryToUpdateIfModified;
54
bool
m_generateMipMaps;
55
Eegeo::Web::IWebLoadRequest
* m_pWebLoadRequest;
56
ITextureFactory
& m_textureFactory;
57
};
58
}
59
}
60
}
Generated on Sat Jun 10 2023 02:00:31 for eeGeo Platform SDK by
1.8.3.1