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

Unified Diff: gpu/command_buffer/service/framebuffer_manager.h

Issue 12545014: Implement EXT_draw_buffers WebGL extention support in command buffer. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 7 years, 9 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 | « gpu/command_buffer/service/feature_info.cc ('k') | gpu/command_buffer/service/framebuffer_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gpu/command_buffer/service/framebuffer_manager.h
===================================================================
--- gpu/command_buffer/service/framebuffer_manager.h (revision 187725)
+++ gpu/command_buffer/service/framebuffer_manager.h (working copy)
@@ -40,7 +40,8 @@
Renderbuffer* renderbuffer) const = 0;
virtual bool CanRenderTo() const = 0;
virtual void DetachFromFramebuffer() const = 0;
- virtual bool ValidForAttachmentType(GLenum attachment_type) = 0;
+ virtual bool ValidForAttachmentType(
+ GLenum attachment_type, uint32 max_color_attachments) = 0;
virtual void AddToSignature(
TextureManager* texture_manager, std::string* signature) const = 0;
@@ -114,6 +115,10 @@
// Check all attachments are cleared
bool IsCleared() const;
+ GLenum GetDrawBuffer(GLenum draw_buffer) const;
+
+ void SetDrawBuffers(GLsizei n, const GLenum* bufs);
+
static void ClearFramebufferCompleteComboMap();
private:
@@ -160,6 +165,8 @@
typedef base::hash_map<std::string, bool> FramebufferComboCompleteMap;
static FramebufferComboCompleteMap* framebuffer_combo_complete_map_;
+ scoped_array<GLenum> draw_buffers_;
+
DISALLOW_COPY_AND_ASSIGN(Framebuffer);
};
@@ -167,7 +174,7 @@
// so we can correctly clear them.
class GPU_EXPORT FramebufferManager {
public:
- FramebufferManager();
+ FramebufferManager(uint32 max_draw_buffers, uint32 max_color_attachments);
~FramebufferManager();
// Must call before destruction.
@@ -221,6 +228,9 @@
bool have_context_;
+ uint32 max_draw_buffers_;
+ uint32 max_color_attachments_;
+
DISALLOW_COPY_AND_ASSIGN(FramebufferManager);
};
« no previous file with comments | « gpu/command_buffer/service/feature_info.cc ('k') | gpu/command_buffer/service/framebuffer_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698