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

Side by Side Diff: gpu/command_buffer/service/gles2_cmd_decoder.cc

Issue 6670074: GPU process - parent GL context does not delete the textures it shares with c... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 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
« no previous file with comments | « no previous file | gpu/command_buffer/service/texture_manager.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" 5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h"
6 6
7 #include <stdio.h> 7 #include <stdio.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <list> 10 #include <list>
11 #include <map> 11 #include <map>
(...skipping 1953 matching lines...) Expand 10 before | Expand all | Expand 10 after
1965 // 1965 //
1966 offscreen_saved_color_texture_.reset(new Texture(this)); 1966 offscreen_saved_color_texture_.reset(new Texture(this));
1967 offscreen_saved_color_texture_->Create(); 1967 offscreen_saved_color_texture_->Create();
1968 1968
1969 // Map the ID of the saved offscreen texture into the parent so that 1969 // Map the ID of the saved offscreen texture into the parent so that
1970 // it can reference it. 1970 // it can reference it.
1971 if (parent_) { 1971 if (parent_) {
1972 GLuint service_id = offscreen_saved_color_texture_->id(); 1972 GLuint service_id = offscreen_saved_color_texture_->id();
1973 TextureManager::TextureInfo* info = 1973 TextureManager::TextureInfo* info =
1974 parent_->CreateTextureInfo(parent_client_texture_id, service_id); 1974 parent_->CreateTextureInfo(parent_client_texture_id, service_id);
1975 info->SetNotOwned();
1975 parent_->texture_manager()->SetInfoTarget(info, GL_TEXTURE_2D); 1976 parent_->texture_manager()->SetInfoTarget(info, GL_TEXTURE_2D);
1976 } 1977 }
1977 1978
1978 // Allocate the render buffers at their initial size and check the status 1979 // Allocate the render buffers at their initial size and check the status
1979 // of the frame buffers is okay. 1980 // of the frame buffers is okay.
1980 pending_offscreen_size_ = size; 1981 pending_offscreen_size_ = size;
1981 if (!UpdateOffscreenFrameBufferSize()) { 1982 if (!UpdateOffscreenFrameBufferSize()) {
1982 LOG(ERROR) << "Could not allocate offscreen buffer storage."; 1983 LOG(ERROR) << "Could not allocate offscreen buffer storage.";
1983 Destroy(); 1984 Destroy();
1984 return false; 1985 return false;
(...skipping 4225 matching lines...) Expand 10 before | Expand all | Expand 10 after
6210 return error::kNoError; 6211 return error::kNoError;
6211 } 6212 }
6212 6213
6213 // Include the auto-generated part of this file. We split this because it means 6214 // Include the auto-generated part of this file. We split this because it means
6214 // we can easily edit the non-auto generated parts right here in this file 6215 // we can easily edit the non-auto generated parts right here in this file
6215 // instead of having to edit some template or the code generator. 6216 // instead of having to edit some template or the code generator.
6216 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" 6217 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h"
6217 6218
6218 } // namespace gles2 6219 } // namespace gles2
6219 } // namespace gpu 6220 } // namespace gpu
OLDNEW
« no previous file with comments | « no previous file | gpu/command_buffer/service/texture_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698