Skip to content

Commit 26c88bb

Browse files
committed
Remove more lingering unused methods
1 parent aeb5a39 commit 26c88bb

File tree

2 files changed

+0
-37
lines changed

2 files changed

+0
-37
lines changed

src/webgl/p5.Shader.js

-25
Original file line numberDiff line numberDiff line change
@@ -1325,31 +1325,6 @@ function shader(p5, fn){
13251325
return this;
13261326
}
13271327

1328-
/* NONE OF THIS IS FAST OR EFFICIENT BUT BEAR WITH ME
1329-
*
1330-
* these shader "type" query methods are used by various
1331-
* facilities of the renderer to determine if changing
1332-
* the shader type for the required action (for example,
1333-
* do we need to load the default lighting shader if the
1334-
* current shader cannot handle lighting?)
1335-
*
1336-
**/
1337-
1338-
isNormalShader() {
1339-
return this.attributes.aNormal !== undefined;
1340-
}
1341-
1342-
isTextureShader() {
1343-
return this.samplers.length > 0;
1344-
}
1345-
1346-
isColorShader() {
1347-
return (
1348-
this.attributes.aVertexColor !== undefined ||
1349-
this.uniforms.uMaterialColor !== undefined
1350-
);
1351-
}
1352-
13531328
/**
13541329
* @chainable
13551330
* @private

test/unit/webgl/p5.Shader.js

-12
Original file line numberDiff line numberDiff line change
@@ -256,18 +256,6 @@ suite('p5.Shader', function() {
256256
assert.isTrue(curShader === null);
257257
});
258258

259-
test('isNormalShader returns true if there is a normal attribute', function() {
260-
var s = myp5._renderer._getNormalShader();
261-
myp5.shader(s);
262-
assert.isTrue(s.isNormalShader());
263-
});
264-
265-
test('isNormalShader returns false if there is no normal attribute', function() {
266-
var s = myp5._renderer._getPointShader();
267-
myp5.shader(s);
268-
assert.isFalse(s.isNormalShader());
269-
});
270-
271259
suite('Hooks', function() {
272260
let myShader;
273261

0 commit comments

Comments
 (0)