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

Side by Side Diff: sky/engine/platform/graphics/gpu/DrawingBuffer.cpp

Issue 691663002: Unfork Sky's trace events (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 1 month 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 /* 1 /*
2 * Copyright (c) 2010, Google Inc. All rights reserved. 2 * Copyright (c) 2010, Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
143 , m_colorFormat(0) 143 , m_colorFormat(0)
144 , m_internalRenderbufferFormat(0) 144 , m_internalRenderbufferFormat(0)
145 , m_maxTextureSize(0) 145 , m_maxTextureSize(0)
146 , m_sampleCount(0) 146 , m_sampleCount(0)
147 , m_packAlignment(4) 147 , m_packAlignment(4)
148 , m_destructionInProgress(false) 148 , m_destructionInProgress(false)
149 , m_isHidden(false) 149 , m_isHidden(false)
150 , m_contextEvictionManager(contextEvictionManager) 150 , m_contextEvictionManager(contextEvictionManager)
151 { 151 {
152 // Used by browser tests to detect the use of a DrawingBuffer. 152 // Used by browser tests to detect the use of a DrawingBuffer.
153 TRACE_EVENT_INSTANT0("test_gpu", "DrawingBufferCreation"); 153 TRACE_EVENT_INSTANT0("test_gpu", "DrawingBufferCreation", TRACE_EVENT_SCOPE_ NAME_PROCESS);
154 #ifndef NDEBUG 154 #ifndef NDEBUG
155 drawingBufferCounter.increment(); 155 drawingBufferCounter.increment();
156 #endif 156 #endif
157 } 157 }
158 158
159 DrawingBuffer::~DrawingBuffer() 159 DrawingBuffer::~DrawingBuffer()
160 { 160 {
161 ASSERT(m_destructionInProgress); 161 ASSERT(m_destructionInProgress);
162 ASSERT(m_textureMailboxes.isEmpty()); 162 ASSERT(m_textureMailboxes.isEmpty());
163 m_layer.clear(); 163 m_layer.clear();
(...skipping 881 matching lines...) Expand 10 before | Expand all | Expand 10 after
1045 void DrawingBuffer::deleteChromiumImageForTexture(TextureInfo* info) 1045 void DrawingBuffer::deleteChromiumImageForTexture(TextureInfo* info)
1046 { 1046 {
1047 if (info->imageId) { 1047 if (info->imageId) {
1048 m_context->releaseTexImage2DCHROMIUM(GL_TEXTURE_2D, info->imageId); 1048 m_context->releaseTexImage2DCHROMIUM(GL_TEXTURE_2D, info->imageId);
1049 m_context->destroyImageCHROMIUM(info->imageId); 1049 m_context->destroyImageCHROMIUM(info->imageId);
1050 info->imageId = 0; 1050 info->imageId = 0;
1051 } 1051 }
1052 } 1052 }
1053 1053
1054 } // namespace blink 1054 } // namespace blink
OLDNEW
« no previous file with comments | « sky/engine/platform/graphics/OpaqueRectTrackingContentLayerDelegate.cpp ('k') | sky/engine/web/WebViewImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698