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

Side by Side Diff: webkit/gpu/webgraphicscontext3d_in_process_impl.h

Issue 12896006: mac: Clean up a few more uses of USE_SKIA (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: mac 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 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 WEBKIT_GPU_WEBGRAPHICSCONTEXT3D_IN_PROCESS_IMPL_H_ 5 #ifndef WEBKIT_GPU_WEBGRAPHICSCONTEXT3D_IN_PROCESS_IMPL_H_
6 #define WEBKIT_GPU_WEBGRAPHICSCONTEXT3D_IN_PROCESS_IMPL_H_ 6 #define WEBKIT_GPU_WEBGRAPHICSCONTEXT3D_IN_PROCESS_IMPL_H_
7 7
8 #include <list> 8 #include <list>
9 #include <set> 9 #include <set>
10 10
11 #include "base/compiler_specific.h" 11 #include "base/compiler_specific.h"
12 #include "base/hash_tables.h" 12 #include "base/hash_tables.h"
13 #include "base/memory/ref_counted.h" 13 #include "base/memory/ref_counted.h"
14 #include "third_party/WebKit/Source/Platform/chromium/public/WebGraphicsContext3 D.h" 14 #include "third_party/WebKit/Source/Platform/chromium/public/WebGraphicsContext3 D.h"
15 #include "third_party/WebKit/Source/Platform/chromium/public/WebString.h" 15 #include "third_party/WebKit/Source/Platform/chromium/public/WebString.h"
16 #include "third_party/angle/include/GLSLANG/ShaderLang.h" 16 #include "third_party/angle/include/GLSLANG/ShaderLang.h"
17 #include "ui/gfx/native_widget_types.h" 17 #include "ui/gfx/native_widget_types.h"
18 #include "webkit/gpu/webkit_gpu_export.h" 18 #include "webkit/gpu/webkit_gpu_export.h"
19 19
20 #if !defined(OS_MACOSX)
21 #define FLIP_FRAMEBUFFER_VERTICALLY
22 #endif
23 namespace gfx { 20 namespace gfx {
24 class GLContext; 21 class GLContext;
25 class GLSurface; 22 class GLSurface;
26 class GLShareGroup; 23 class GLShareGroup;
27 } 24 }
28 25
29 using WebKit::WGC3Dbyte; 26 using WebKit::WGC3Dbyte;
30 using WebKit::WGC3Dchar; 27 using WebKit::WGC3Dchar;
31 using WebKit::WGC3Denum; 28 using WebKit::WGC3Denum;
32 using WebKit::WGC3Dboolean; 29 using WebKit::WGC3Dboolean;
(...skipping 475 matching lines...) Expand 10 before | Expand all | Expand 10 after
508 bool Initialize(Attributes attributes); 505 bool Initialize(Attributes attributes);
509 506
510 // ANGLE related. 507 // ANGLE related.
511 struct ShaderSourceEntry; 508 struct ShaderSourceEntry;
512 509
513 typedef base::hash_map<WebGLId, ShaderSourceEntry*> ShaderSourceMap; 510 typedef base::hash_map<WebGLId, ShaderSourceEntry*> ShaderSourceMap;
514 511
515 bool AllocateOffscreenFrameBuffer(int width, int height); 512 bool AllocateOffscreenFrameBuffer(int width, int height);
516 void ClearRenderTarget(); 513 void ClearRenderTarget();
517 514
518 #ifdef FLIP_FRAMEBUFFER_VERTICALLY
519 void FlipVertically(unsigned char* framebuffer, 515 void FlipVertically(unsigned char* framebuffer,
520 unsigned int width, 516 unsigned int width,
521 unsigned int height); 517 unsigned int height);
522 #endif
523 518
524 // Take into account the user's requested context creation attributes, in 519 // Take into account the user's requested context creation attributes, in
525 // particular stencil and antialias, and determine which could or could 520 // particular stencil and antialias, and determine which could or could
526 // not be honored based on the capabilities of the OpenGL implementation. 521 // not be honored based on the capabilities of the OpenGL implementation.
527 void ValidateAttributes(); 522 void ValidateAttributes();
528 523
529 // Resolve the given rectangle of the multisampled framebuffer if necessary. 524 // Resolve the given rectangle of the multisampled framebuffer if necessary.
530 void ResolveMultisampledFramebuffer( 525 void ResolveMultisampledFramebuffer(
531 WGC3Dint x, WGC3Dint y, WGC3Dsizei width, WGC3Dsizei height); 526 WGC3Dint x, WGC3Dint y, WGC3Dsizei width, WGC3Dsizei height);
532 527
(...skipping 20 matching lines...) Expand all
553 WebGLId multisample_fbo_; 548 WebGLId multisample_fbo_;
554 WebGLId multisample_depth_stencil_buffer_; 549 WebGLId multisample_depth_stencil_buffer_;
555 WebGLId multisample_color_buffer_; 550 WebGLId multisample_color_buffer_;
556 551
557 // For tracking which FBO is bound 552 // For tracking which FBO is bound
558 WebGLId bound_fbo_; 553 WebGLId bound_fbo_;
559 554
560 // For tracking which texture is bound 555 // For tracking which texture is bound
561 WebGLId bound_texture_; 556 WebGLId bound_texture_;
562 557
563 #ifdef FLIP_FRAMEBUFFER_VERTICALLY
564 unsigned char* scanline_; 558 unsigned char* scanline_;
565 #endif
566 559
567 // Errors raised by synthesizeGLError(). 560 // Errors raised by synthesizeGLError().
568 std::list<WGC3Denum> synthetic_errors_list_; 561 std::list<WGC3Denum> synthetic_errors_list_;
569 std::set<WGC3Denum> synthetic_errors_set_; 562 std::set<WGC3Denum> synthetic_errors_set_;
570 563
571 scoped_refptr<gfx::GLContext> gl_context_; 564 scoped_refptr<gfx::GLContext> gl_context_;
572 scoped_refptr<gfx::GLSurface> gl_surface_; 565 scoped_refptr<gfx::GLSurface> gl_surface_;
573 566
574 ShaderSourceMap shader_source_map_; 567 ShaderSourceMap shader_source_map_;
575 568
576 ShHandle fragment_compiler_; 569 ShHandle fragment_compiler_;
577 ShHandle vertex_compiler_; 570 ShHandle vertex_compiler_;
578 }; 571 };
579 572
580 } // namespace gpu 573 } // namespace gpu
581 } // namespace webkit 574 } // namespace webkit
582 575
583 #endif // WEBKIT_GPU_WEBGRAPHICSCONTEXT3D_IN_PROCESS_IMPL_H_ 576 #endif // WEBKIT_GPU_WEBGRAPHICSCONTEXT3D_IN_PROCESS_IMPL_H_
OLDNEW
« no previous file with comments | « webkit/gpu/webgraphicscontext3d_in_process_command_buffer_impl.cc ('k') | webkit/gpu/webgraphicscontext3d_in_process_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698