Skip to content

Commit

Permalink
webgl1 examples correctly flagged
Browse files Browse the repository at this point in the history
  • Loading branch information
slimbuck committed May 21, 2024
1 parent 9ff94f9 commit f18375a
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
// @config WEBGPU_DISABLED
// @config WEBGL1_DISABLED
import * as pc from 'playcanvas';
import { data } from '@examples/observer';
import { deviceType, rootPath } from '@examples/utils';
Expand Down
6 changes: 4 additions & 2 deletions examples/src/examples/graphics/grab-pass.shader.frag
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,10 @@ void main(void)
vec3 grabColor = texture2DLodEXT(uSceneColorMap, grabUv + offset, mipmap).rgb;

// tint the material based on mipmap
float tintIndex = clamp(mipmap, 0.0, 3.0);
grabColor *= tints[int(tintIndex)];
#ifdef GL2
float tintIndex = clamp(mipmap, 0.0, 3.0);
grabColor *= tints[int(tintIndex)];
#endif

// brighten the refracted texture a little bit
// brighten even more the rough parts of the glass
Expand Down
2 changes: 2 additions & 0 deletions examples/src/examples/loaders/gsplat-many.example.mjs
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// @config WEBGL1_DISABLED

import * as pc from 'playcanvas';
import { data } from '@examples/observer';
import files from '@examples/files';
Expand Down
2 changes: 2 additions & 0 deletions examples/src/examples/loaders/gsplat.example.mjs
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// @config WEBGL1_DISABLED

import * as pc from 'playcanvas';
import { deviceType, rootPath } from '@examples/utils';

Expand Down

0 comments on commit f18375a

Please sign in to comment.