Skip to content

Commit 8536049

Browse files
committed
Fixed shaderType reference
1 parent b22f5ce commit 8536049

1 file changed

Lines changed: 6 additions & 4 deletions

File tree

src/loader/filetypes/GLSLFile.js

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ var GLSLFile = new Class({
6464
}
6565
else if (shaderType === undefined)
6666
{
67-
shaderType = 'frag';
67+
shaderType = 'fragment';
6868
}
6969

7070
var fileConfig = {
@@ -74,7 +74,9 @@ var GLSLFile = new Class({
7474
responseType: 'text',
7575
key: key,
7676
url: url,
77-
shaderType: shaderType,
77+
config: {
78+
shaderType: shaderType
79+
},
7880
xhrSettings: xhrSettings
7981
};
8082

@@ -152,11 +154,11 @@ var GLSLFile = new Class({
152154
else if (this.config.shaderType === 'fragment')
153155
{
154156
// Single shader
155-
this.cache.add(this.key, new Shader(this.key, data));
157+
this.cache.add(this.key, new Shader(this.key, this.data));
156158
}
157159
else
158160
{
159-
this.cache.add(this.key, new Shader(this.key, '', data));
161+
this.cache.add(this.key, new Shader(this.key, '', this.data));
160162
}
161163

162164
this.pendingDestroy();

0 commit comments

Comments
 (0)