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

Unified Diff: core/win/d3d9/renderer_d3d9.cc

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/texture.cc ('k') | core/win/d3d9/texture_d3d9.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/win/d3d9/renderer_d3d9.cc
===================================================================
--- core/win/d3d9/renderer_d3d9.cc (revision 20557)
+++ core/win/d3d9/renderer_d3d9.cc (working copy)
@@ -1663,13 +1663,13 @@
Texture::Format format,
int levels,
bool enable_render_surfaces) {
- Bitmap bitmap;
- bitmap.set_format(format);
- bitmap.set_width(width);
- bitmap.set_height(height);
- bitmap.set_num_mipmaps(levels);
+ Bitmap::Ref bitmap = Bitmap::Ref(new Bitmap(service_locator()));
+ bitmap->set_format(format);
+ bitmap->set_width(width);
+ bitmap->set_height(height);
+ bitmap->set_num_mipmaps(levels);
return Texture2D::Ref(Texture2DD3D9::Create(service_locator(),
- &bitmap,
+ bitmap,
this,
enable_render_surfaces));
}
@@ -1681,14 +1681,14 @@
Texture::Format format,
int levels,
bool enable_render_surfaces) {
- Bitmap bitmap;
- bitmap.set_format(format);
- bitmap.set_width(edge_length);
- bitmap.set_height(edge_length);
- bitmap.set_num_mipmaps(levels);
- bitmap.set_is_cubemap(true);
+ Bitmap::Ref bitmap = Bitmap::Ref(new Bitmap(service_locator()));
+ bitmap->set_format(format);
+ bitmap->set_width(edge_length);
+ bitmap->set_height(edge_length);
+ bitmap->set_num_mipmaps(levels);
+ bitmap->set_is_cubemap(true);
return TextureCUBE::Ref(TextureCUBED3D9::Create(service_locator(),
- &bitmap,
+ bitmap,
this,
enable_render_surfaces));
}
« no previous file with comments | « core/cross/texture.cc ('k') | core/win/d3d9/texture_d3d9.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698