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

Side by Side Diff: content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.h

Issue 25455002: Remove WGC3D::width(), height(), reshape() implementations (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 2 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_COMMON_GPU_CLIENT_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_ 5 #ifndef CONTENT_COMMON_GPU_CLIENT_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_
6 #define CONTENT_COMMON_GPU_CLIENT_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_ 6 #define CONTENT_COMMON_GPU_CLIENT_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 //---------------------------------------------------------------------- 137 //----------------------------------------------------------------------
138 // WebGraphicsContext3D methods 138 // WebGraphicsContext3D methods
139 139
140 // Must be called after initialize() and before any of the following methods. 140 // Must be called after initialize() and before any of the following methods.
141 // Permanently binds to the first calling thread. Returns false if the 141 // Permanently binds to the first calling thread. Returns false if the
142 // graphics context fails to create. Do not call from more than one thread. 142 // graphics context fails to create. Do not call from more than one thread.
143 virtual bool makeContextCurrent(); 143 virtual bool makeContextCurrent();
144 144
145 virtual uint32_t lastFlushID(); 145 virtual uint32_t lastFlushID();
146 146
147 virtual int width();
148 virtual int height();
149
150 virtual unsigned int insertSyncPoint(); 147 virtual unsigned int insertSyncPoint();
151 virtual void waitSyncPoint(unsigned int sync_point); 148 virtual void waitSyncPoint(unsigned int sync_point);
152 virtual void signalSyncPoint(unsigned sync_point, 149 virtual void signalSyncPoint(unsigned sync_point,
153 WebGraphicsSyncPointCallback* callback); 150 WebGraphicsSyncPointCallback* callback);
154 virtual void signalQuery(unsigned query, 151 virtual void signalQuery(unsigned query,
155 WebGraphicsSyncPointCallback* callback); 152 WebGraphicsSyncPointCallback* callback);
156 153
157 virtual void loseContextCHROMIUM(WGC3Denum current, WGC3Denum other); 154 virtual void loseContextCHROMIUM(WGC3Denum current, WGC3Denum other);
158 155
159 virtual void reshape(int width, int height);
160 virtual void reshapeWithScaleFactor( 156 virtual void reshapeWithScaleFactor(
161 int width, int height, float scale_factor); 157 int width, int height, float scale_factor);
162 158
163 virtual void prepareTexture(); 159 virtual void prepareTexture();
164 virtual void postSubBufferCHROMIUM(int x, int y, int width, int height); 160 virtual void postSubBufferCHROMIUM(int x, int y, int width, int height);
165 161
166 virtual void activeTexture(WGC3Denum texture); 162 virtual void activeTexture(WGC3Denum texture);
167 virtual void attachShader(WebGLId program, WebGLId shader); 163 virtual void attachShader(WebGLId program, WebGLId shader);
168 virtual void bindAttribLocation(WebGLId program, WGC3Duint index, 164 virtual void bindAttribLocation(WebGLId program, WGC3Duint index,
169 const WGC3Dchar* name); 165 const WGC3Dchar* name);
(...skipping 564 matching lines...) Expand 10 before | Expand all | Expand 10 after
734 WebGraphicsContext3D::WebGraphicsErrorMessageCallback* 730 WebGraphicsContext3D::WebGraphicsErrorMessageCallback*
735 error_message_callback_; 731 error_message_callback_;
736 scoped_ptr<WebGraphicsContext3DErrorMessageCallback> 732 scoped_ptr<WebGraphicsContext3DErrorMessageCallback>
737 client_error_message_callback_; 733 client_error_message_callback_;
738 734
739 WebGraphicsContext3D::WebGraphicsSwapBuffersCompleteCallbackCHROMIUM* 735 WebGraphicsContext3D::WebGraphicsSwapBuffersCompleteCallbackCHROMIUM*
740 swapbuffers_complete_callback_; 736 swapbuffers_complete_callback_;
741 737
742 WebKit::WebGraphicsContext3D::Attributes attributes_; 738 WebKit::WebGraphicsContext3D::Attributes attributes_;
743 gfx::GpuPreference gpu_preference_; 739 gfx::GpuPreference gpu_preference_;
744 int cached_width_, cached_height_;
745 740
746 // Errors raised by synthesizeGLError(). 741 // Errors raised by synthesizeGLError().
747 std::vector<WGC3Denum> synthetic_errors_; 742 std::vector<WGC3Denum> synthetic_errors_;
748 743
749 base::WeakPtrFactory<WebGraphicsContext3DCommandBufferImpl> weak_ptr_factory_; 744 base::WeakPtrFactory<WebGraphicsContext3DCommandBufferImpl> weak_ptr_factory_;
750 745
751 bool initialized_; 746 bool initialized_;
752 scoped_ptr<CommandBufferProxyImpl> command_buffer_; 747 scoped_ptr<CommandBufferProxyImpl> command_buffer_;
753 scoped_ptr<gpu::gles2::GLES2CmdHelper> gles2_helper_; 748 scoped_ptr<gpu::gles2::GLES2CmdHelper> gles2_helper_;
754 scoped_ptr<gpu::TransferBuffer> transfer_buffer_; 749 scoped_ptr<gpu::TransferBuffer> transfer_buffer_;
755 gpu::gles2::GLES2Interface* gl_; 750 gpu::gles2::GLES2Interface* gl_;
756 scoped_ptr<gpu::gles2::GLES2Implementation> real_gl_; 751 scoped_ptr<gpu::gles2::GLES2Implementation> real_gl_;
757 scoped_ptr<gpu::gles2::GLES2Interface> trace_gl_; 752 scoped_ptr<gpu::gles2::GLES2Interface> trace_gl_;
758 Error last_error_; 753 Error last_error_;
759 int frame_number_; 754 int frame_number_;
760 bool bind_generates_resources_; 755 bool bind_generates_resources_;
761 bool use_echo_for_swap_ack_; 756 bool use_echo_for_swap_ack_;
762 size_t command_buffer_size_; 757 size_t command_buffer_size_;
763 size_t start_transfer_buffer_size_; 758 size_t start_transfer_buffer_size_;
764 size_t min_transfer_buffer_size_; 759 size_t min_transfer_buffer_size_;
765 size_t max_transfer_buffer_size_; 760 size_t max_transfer_buffer_size_;
766 size_t mapped_memory_limit_; 761 size_t mapped_memory_limit_;
767 762
768 uint32_t flush_id_; 763 uint32_t flush_id_;
769 }; 764 };
770 765
771 } // namespace content 766 } // namespace content
772 767
773 #endif // CONTENT_COMMON_GPU_CLIENT_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_ 768 #endif // CONTENT_COMMON_GPU_CLIENT_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_
OLDNEW
« no previous file with comments | « cc/debug/test_web_graphics_context_3d.cc ('k') | content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698