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

Side by Side Diff: third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp

Issue 2610853005: Modify Copy{Sub}TextureCHROMIUM entry point to add level argument (Closed)
Patch Set: fix chromeos Created 3 years, 11 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 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after
246 if (!imageInfo) 246 if (!imageInfo)
247 return false; 247 return false;
248 248
249 gpu::gles2::GLES2Interface* gl = contextGL(); 249 gpu::gles2::GLES2Interface* gl = contextGL();
250 if (!gl) 250 if (!gl)
251 return false; 251 return false;
252 252
253 GLuint imageTexture = 253 GLuint imageTexture =
254 skia::GrBackendObjectToGrGLTextureInfo(image->getTextureHandle(true)) 254 skia::GrBackendObjectToGrGLTextureInfo(image->getTextureHandle(true))
255 ->fID; 255 ->fID;
256 gl->CopySubTextureCHROMIUM(imageTexture, imageInfo->m_textureId, 0, 0, 0, 0, 256 gl->CopySubTextureCHROMIUM(imageTexture, 0, imageInfo->m_textureId, 0, 0, 0,
257 m_size.width(), m_size.height(), GL_FALSE, 257 0, 0, m_size.width(), m_size.height(), GL_FALSE,
258 GL_FALSE, GL_FALSE); 258 GL_FALSE, GL_FALSE);
259 259
260 MailboxInfo& info = m_mailboxes.first(); 260 MailboxInfo& info = m_mailboxes.first();
261 uint32_t textureTarget = GC3D_TEXTURE_RECTANGLE_ARB; 261 uint32_t textureTarget = GC3D_TEXTURE_RECTANGLE_ARB;
262 gpu::Mailbox mailbox; 262 gpu::Mailbox mailbox;
263 gl->GenMailboxCHROMIUM(mailbox.name); 263 gl->GenMailboxCHROMIUM(mailbox.name);
264 gl->ProduceTextureDirectCHROMIUM(imageInfo->m_textureId, textureTarget, 264 gl->ProduceTextureDirectCHROMIUM(imageInfo->m_textureId, textureTarget,
265 mailbox.name); 265 mailbox.name);
266 266
267 const GLuint64 fenceSync = gl->InsertFenceSyncCHROMIUM(); 267 const GLuint64 fenceSync = gl->InsertFenceSyncCHROMIUM();
(...skipping 873 matching lines...) Expand 10 before | Expand all | Expand 10 after
1141 default; 1141 default;
1142 1142
1143 void Canvas2DLayerBridge::Logger::reportHibernationEvent( 1143 void Canvas2DLayerBridge::Logger::reportHibernationEvent(
1144 HibernationEvent event) { 1144 HibernationEvent event) {
1145 DEFINE_STATIC_LOCAL(EnumerationHistogram, hibernationHistogram, 1145 DEFINE_STATIC_LOCAL(EnumerationHistogram, hibernationHistogram,
1146 ("Canvas.HibernationEvents", HibernationEventCount)); 1146 ("Canvas.HibernationEvents", HibernationEventCount));
1147 hibernationHistogram.count(event); 1147 hibernationHistogram.count(event);
1148 } 1148 }
1149 1149
1150 } // namespace blink 1150 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698