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

Side by Side Diff: gpu/command_buffer/service/texture_manager.h

Issue 2378583003: Ping watchdog thread during GpuChannel destruction (Closed)
Patch Set: Created 4 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
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 GPU_COMMAND_BUFFER_SERVICE_TEXTURE_MANAGER_H_ 5 #ifndef GPU_COMMAND_BUFFER_SERVICE_TEXTURE_MANAGER_H_
6 #define GPU_COMMAND_BUFFER_SERVICE_TEXTURE_MANAGER_H_ 6 #define GPU_COMMAND_BUFFER_SERVICE_TEXTURE_MANAGER_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 20 matching lines...) Expand all
31 31
32 class GLES2Decoder; 32 class GLES2Decoder;
33 class GLStreamTextureImage; 33 class GLStreamTextureImage;
34 struct ContextState; 34 struct ContextState;
35 struct DecoderFramebufferState; 35 struct DecoderFramebufferState;
36 class Display; 36 class Display;
37 class ErrorState; 37 class ErrorState;
38 class FeatureInfo; 38 class FeatureInfo;
39 class FramebufferManager; 39 class FramebufferManager;
40 class MailboxManager; 40 class MailboxManager;
41 class ProgressReporter;
41 class Texture; 42 class Texture;
42 class TextureManager; 43 class TextureManager;
43 class TextureRef; 44 class TextureRef;
44 45
45 class GPU_EXPORT TextureBase { 46 class GPU_EXPORT TextureBase {
46 public: 47 public:
47 explicit TextureBase(GLuint service_id); 48 explicit TextureBase(GLuint service_id);
48 virtual ~TextureBase(); 49 virtual ~TextureBase();
49 50
50 // The service side OpenGL id of the texture. 51 // The service side OpenGL id of the texture.
(...skipping 718 matching lines...) Expand 10 before | Expand all | Expand 10 after
769 ~TextureManager() override; 770 ~TextureManager() override;
770 771
771 void set_framebuffer_manager(FramebufferManager* manager) { 772 void set_framebuffer_manager(FramebufferManager* manager) {
772 framebuffer_manager_ = manager; 773 framebuffer_manager_ = manager;
773 } 774 }
774 775
775 // Init the texture manager. 776 // Init the texture manager.
776 bool Initialize(); 777 bool Initialize();
777 778
778 // Must call before destruction. 779 // Must call before destruction.
779 void Destroy(bool have_context); 780 void Destroy(bool have_context, ProgressReporter* progress_reporter);
780 781
781 // Returns the maximum number of levels. 782 // Returns the maximum number of levels.
782 GLint MaxLevelsForTarget(GLenum target) const { 783 GLint MaxLevelsForTarget(GLenum target) const {
783 switch (target) { 784 switch (target) {
784 case GL_TEXTURE_2D: 785 case GL_TEXTURE_2D:
785 case GL_TEXTURE_2D_ARRAY: 786 case GL_TEXTURE_2D_ARRAY:
786 return max_levels_; 787 return max_levels_;
787 case GL_TEXTURE_RECTANGLE_ARB: 788 case GL_TEXTURE_RECTANGLE_ARB:
788 case GL_TEXTURE_EXTERNAL_OES: 789 case GL_TEXTURE_EXTERNAL_OES:
789 return 1; 790 return 1;
(...skipping 457 matching lines...) Expand 10 before | Expand all | Expand 10 after
1247 private: 1248 private:
1248 DecoderTextureState* texture_state_; 1249 DecoderTextureState* texture_state_;
1249 base::TimeTicks begin_time_; 1250 base::TimeTicks begin_time_;
1250 DISALLOW_COPY_AND_ASSIGN(ScopedTextureUploadTimer); 1251 DISALLOW_COPY_AND_ASSIGN(ScopedTextureUploadTimer);
1251 }; 1252 };
1252 1253
1253 } // namespace gles2 1254 } // namespace gles2
1254 } // namespace gpu 1255 } // namespace gpu
1255 1256
1256 #endif // GPU_COMMAND_BUFFER_SERVICE_TEXTURE_MANAGER_H_ 1257 #endif // GPU_COMMAND_BUFFER_SERVICE_TEXTURE_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698