Index: core/cross/cairo/texture_cairo.h |
=================================================================== |
--- core/cross/cairo/texture_cairo.h (revision 57528) |
+++ core/cross/cairo/texture_cairo.h (working copy) |
@@ -42,6 +42,21 @@ |
class RendererCairo; |
+struct TextureResource { |
+ // Current Frame Data Source |
+ const void* data; |
+ // X coordinate |
+ unsigned left; |
+ // Y coordinate |
+ unsigned top; |
+ // Current Frame Source Width |
+ unsigned width; |
+ // Current Frame Source Height |
+ unsigned height; |
+ // Current Frame Source Pitch |
+ int pitch; |
+}; |
+ |
// Texture2DCairo implements the Texture2D interface. |
class TextureCairo : public Texture2D { |
public: |
@@ -68,6 +83,8 @@ |
const void* src_data, |
int src_pitch); |
+ virtual TextureResource* GetResource(); |
+ |
// Gets a RGBASwizzleIndices that contains a mapping from |
// RGBA to the internal format used by the rendering API. |
virtual const RGBASwizzleIndices& GetABGR32FSwizzleIndices(); |
@@ -86,9 +103,12 @@ |
// Returns the implementation-specific texture handle for this texture. |
virtual void* GetTextureHandle() const; |
- // The 2d renderer object to be used by client |
+ // The 2d renderer object to be used by client. |
RendererCairo* renderer_; |
+ // Texture Resource for this particular instance. |
+ TextureResource resource_; |
+ |
private: |
// Initializes the Texture2D. |
TextureCairo(ServiceLocator* service_locator, |