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

Side by Side Diff: third_party/WebKit/Source/modules/webgl/WebGLTexture.cpp

Issue 1815803003: Move simple methods [T-Z] from WebGraphicsContext3D to GLES2Interface. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@simples-fplus
Patch Set: simples-tplus: fixed Created 4 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2009 Apple 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 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 void WebGLTexture::setTarget(GLenum target) 50 void WebGLTexture::setTarget(GLenum target)
51 { 51 {
52 if (!object()) 52 if (!object())
53 return; 53 return;
54 // Target is finalized the first time bindTexture() is called. 54 // Target is finalized the first time bindTexture() is called.
55 if (m_target) 55 if (m_target)
56 return; 56 return;
57 m_target = target; 57 m_target = target;
58 } 58 }
59 59
60 void WebGLTexture::deleteObjectImpl(WebGraphicsContext3D* context3d) 60 void WebGLTexture::deleteObjectImpl(WebGraphicsContext3D* context3d, gpu::gles2: :GLES2Interface* gl)
61 { 61 {
62 context3d->deleteTexture(m_object); 62 context3d->deleteTexture(m_object);
63 m_object = 0; 63 m_object = 0;
64 } 64 }
65 65
66 int WebGLTexture::mapTargetToIndex(GLenum target) const 66 int WebGLTexture::mapTargetToIndex(GLenum target) const
67 { 67 {
68 if (m_target == GL_TEXTURE_2D) { 68 if (m_target == GL_TEXTURE_2D) {
69 if (target == GL_TEXTURE_2D) 69 if (target == GL_TEXTURE_2D)
70 return 0; 70 return 0;
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 if (x) { 107 if (x) {
108 value = x; 108 value = x;
109 log += shift; 109 log += shift;
110 } 110 }
111 } 111 }
112 ASSERT(value == 1); 112 ASSERT(value == 1);
113 return log + 1; 113 return log + 1;
114 } 114 }
115 115
116 } // namespace blink 116 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/modules/webgl/WebGLTexture.h ('k') | third_party/WebKit/Source/modules/webgl/WebGLTimerQueryEXT.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698