Chromium Code Reviews| Index: core/cross/texture_base.h |
| =================================================================== |
| --- core/cross/texture_base.h (revision 66674) |
| +++ core/cross/texture_base.h (working copy) |
| @@ -117,6 +117,15 @@ |
| return format_; |
| } |
| + int update_count() { |
| + return update_count_; |
| + } |
| + |
| + int render_count() { |
| + CheckLastTextureUpdateRendered(); |
| + return render_count_; |
| + } |
| + |
| bool render_surfaces_enabled() const { |
| return render_surfaces_enabled_; |
| } |
| @@ -142,7 +151,14 @@ |
| format_ = format; |
| } |
| + void TextureUpdated(); |
| + |
| + // The global renderer. |
| + Renderer* renderer_; |
| + |
|
zhurunz
2010/12/04 01:29:49
static is better?
Tristan Schmelcher 2
2010/12/06 18:44:59
Static won't work. Technically it's not a global i
|
| private: |
| + void CheckLastTextureUpdateRendered(); |
| + |
| // The number of mipmap levels contained in this texture. |
| ParamInteger::Ref levels_param_; |
| @@ -157,6 +173,13 @@ |
| bool render_surfaces_enabled_; |
| + // Counting of frames, to allow the page to determine the framerate of dynamic |
| + // textures. |
| + bool has_unrendered_update_; |
| + int last_render_frame_count_; |
| + int update_count_; |
| + int render_count_; |
| + |
| O3D_DECL_CLASS(Texture, ParamObject); |
| DISALLOW_COPY_AND_ASSIGN(Texture); |
| }; |