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

Unified Diff: examples/ganesh_app/texture_uploader.h

Issue 826423008: Use local ids for Surfaces APIs that can only apply to local surfaces (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 11 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 | « examples/bitmap_uploader/bitmap_uploader.cc ('k') | examples/ganesh_app/texture_uploader.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: examples/ganesh_app/texture_uploader.h
diff --git a/examples/ganesh_app/texture_uploader.h b/examples/ganesh_app/texture_uploader.h
index 09d11c90df1060e72c7ef45b27388690d4367e15..e773b1fb5f27b5ff3347d54a8ecfaa0e430ade40 100644
--- a/examples/ganesh_app/texture_uploader.h
+++ b/examples/ganesh_app/texture_uploader.h
@@ -13,7 +13,6 @@
#include "mojo/services/geometry/public/interfaces/geometry.mojom.h"
#include "mojo/services/surfaces/public/interfaces/surface_id.mojom.h"
#include "mojo/services/surfaces/public/interfaces/surfaces.mojom.h"
-#include "mojo/services/surfaces/public/interfaces/surfaces_service.mojom.h"
namespace mojo {
class Shell;
@@ -47,19 +46,18 @@ class TextureUploader : public mojo::SurfaceClient,
void SetIdNamespace(uint32_t id_namespace) override;
void ReturnResources(
mojo::Array<mojo::ReturnedResourcePtr> resources) override;
- void OnSurfaceConnectionCreated(mojo::SurfacePtr surface,
- uint32_t id_namespace);
+
void EnsureSurfaceForSize(const mojo::Size& size);
+ void SendFullyQualifiedID();
Client* client_;
base::WeakPtr<mojo::GLContext> context_;
- mojo::SurfacesServicePtr surfaces_service_;
scoped_ptr<mojo::GLTexture> pending_upload_;
mojo::SurfacePtr surface_;
mojo::Size surface_size_;
uint32_t next_resource_id_;
uint32_t id_namespace_;
- mojo::SurfaceIdPtr surface_id_;
+ uint32_t local_id_;
base::hash_map<uint32_t, mojo::GLTexture*> resource_to_texture_map_;
base::WeakPtrFactory<TextureUploader> weak_factory_;
« no previous file with comments | « examples/bitmap_uploader/bitmap_uploader.cc ('k') | examples/ganesh_app/texture_uploader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698