Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1386)

Unified Diff: core/cross/pack.h

Issue 150058: expose bitmap in js. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/o3d/
Patch Set: '' Created 11 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « core/cross/class_manager.cc ('k') | core/cross/pack.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/cross/pack.h
===================================================================
--- core/cross/pack.h (revision 20557)
+++ core/cross/pack.h (working copy)
@@ -215,6 +215,26 @@
Texture* CreateTextureFromRawData(RawData* raw_data,
bool generate_mips);
+ // Creates a new Bitmap object of the specified size and format and
+ // reserves the necessary resources for it.
+ // Paramters:
+ // width: The width of the bitmap in pixel.
+ // height: The height of the bitmap in pixel.
+ // format: The format of the bitmap.
+ // Returns:
+ // A pointer to the bitmap obejct.
+
+ Bitmap* CreateBitmap(int width, int height, Texture::Format format);
+
+ // Creates a new Bitmap object from RawData.
+ // Parameters:
+ // raw_data: contains the bitmap data in one of the know formats.
+ // file_type: the format of the bitmap data. If UNKNOW, the file
+ // type would determined from the extension.
+ // Returns:
+ // A pointer to the bitmap object.
+ Bitmap* CreateBitmapFromRawData(RawData* raw_data);
+
// Creates a new Texture2D object of the specified size and format and
// reserves the necessary resources for it.
// Parameters:
@@ -404,13 +424,13 @@
}
};
- // Helper method
- Texture* CreateTextureFromBitmap(Bitmap *bitmap, const String& uri);
-
IClassManager* class_manager_;
ObjectManager* object_manager_;
Renderer* renderer_;
+ // helper function
+ Texture* CreateTextureFromBitmap(Bitmap *bitmap, const String& uri);
+
// The set of objects owned by the pack. This container contains all of the
// references that force the lifespan of the contained objects to match
// or exceed that of the pack.
« no previous file with comments | « core/cross/class_manager.cc ('k') | core/cross/pack.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698