53 questions
0
votes
1
answer
152
views
RGBA16UI support across browsers for WebGL2
I was trying to get WebGL2 RGBA16UI textures working, and they seemed to work as shown by the answer from my previous question: How to create a 16 bit unsigned integer/unsigned short 2D texture in ...
0
votes
1
answer
115
views
Enabling GL EXT_blend_minmax
According to this MDN page EXT_blend_minmax has been supported since Chrome 38 and Firefox 47.
I'm trying to use it from Three.js. However, it doesn't work for me with either latest Chrome or latest ...
0
votes
1
answer
182
views
WebGL: use an ArrayBufferView of type Int16Array with texImage2D
I'm trying to use the texImage2d, my ArrayBufferView have a type Int16Array and when I'm using the texImage2D with type INT return me this error:
WebGL: INVALID_ENUM: texImage2D: invalid type
this is ...
0
votes
1
answer
138
views
Is GL_EXT_draw_instanced supported in WebGL1
I want to add instancing to my WebGL application, which works fine using gl_InstanceID for devices running WebGL2. However, I want to also support older devices running WebGL1 - apparently this is ...
0
votes
0
answers
1k
views
Unity web gl game wont display loading screen and just is blank screen
I have been working on a game and trying to upload it to the chrome extension store. When i open it through the manifest or clicking on index.html file it shows a blank screen and does not load at all....
2
votes
0
answers
210
views
Is it possible to filter integer texture in WebGL?
I have read other posts (for example this) that shows how to render integer texture (R16I) via WebGL.
However, it is using the gl.NEAREST for texture filtering for minification and magnification
gl....
0
votes
1
answer
578
views
GLSL-ES3(webGL2): how to test extensions from fragment shader?
In webGL1 it was possible to test the availability of a GLSL extension from a fragment shader using (for instance) #ifdef GL_EXT_shader_texture_lod .
It seems to no longer be working in webGL2 (=GLSL-...
3
votes
1
answer
6k
views
Debugging in WebGL
I am learning WebGL and I can feel that my speed is so slow because I am having a hard time debugging my code. Is there any extension or tool with help of which I can know the value of buffer, ...
0
votes
1
answer
312
views
can I use multiple texture with drawArraysInstancedANGLE?
I try to draw multiple icon on screen and I use drawArraysInstancedANGLE method.
I try to use multiple texture like this but some icons draw diffrent geometry, I can not find what draw like that.
I ...
1
vote
2
answers
1k
views
Supporting WebGL1 + WebGL2
I have a certain library that uses WebGL1 to render things.
It heavily uses float textures and instanced rendering.
Nowadays it seems like support for WebGL1 is pretty weird, with some devices ...
2
votes
0
answers
1k
views
No support for OES_texture_float, but WebGL2 is available
I've been surprised to find out that my Android phone does not support OES_texture_float extension, but fully supports WebGL2, which has floating texture functionality as baseline. What could cause ...
0
votes
0
answers
48
views
Why do the webidl specifications for WebGL extensions have the [NoInterfaceObject] extended attribute
The specification for [NoInterfaceObject] states that the attribute "should not be used in specifications unless required to specify the behavior of legacy APIs".
Is there something about the WebGL ...
0
votes
2
answers
709
views
How can I use WebGL extensions from web_sys in Rust
I'd like to use WebGL Extensions from within Rust code that is compiled to WebAssembly. The web_sys::WebGlRenderingContext has a method get_extension which returns a JsValue.
I expect there is a way ...
2
votes
0
answers
708
views
How to profile WebGL with ext_disjoint_timer_query extension?
In WebGL we have special extension EXT_disjoint_timer_query for proper GPU profiling, but I can't find good manual how to use it. For example initialization below works in my machine
let gl = canvas....
2
votes
1
answer
2k
views
WebGL2 rendering to R32F texture
I can't bind R32F texture to framebuffer, because such textures are not "color renderable by default" according to this source.
But then it says "those features are available as optional extensions".
...
3
votes
1
answer
3k
views
How to create custom shaders using THREE.ShaderLib
I have been trying to learn THREEJS shader materials. So far I understand how uniforms, vertexShader, and fragmentShader play a role in projecting and coloring the vertices and fragments in the world ...
6
votes
1
answer
1k
views
WebGL: Declining support for OES_texture_float on Android
Does anybody know what the deal is with declining support for the WebGL extension OES_texture_float on Android over the years?
https://webglstats.com/webgl/extension/OES_texture_float?platforms=...
0
votes
0
answers
924
views
How to make GL_EXT_draw_buffers extension available?
I want to use the WEBGL_draw_buffers extension. Besides enabling the extension by gl.getExtension('WEBGL_draw_buffers'); in the JavaScript, one apparently has to enable the extension in the shader as ...
3
votes
1
answer
1k
views
The complete list of promoted extensions in WebGL2
I got a chance to update our renderer we use to WebGL2. To make the renderer as backward compatible as possible we keep tracking of loaded extensions( as we did before the upgrade ) and emulate ...
0
votes
1
answer
347
views
Why sRGB extension has lost a constant?
Old WebGL context has EXT_sRGB extension. That extension exposes 4 constants:
{
SRGB_EXT : 35904,
SRGB_ALPHA_EXT : 35906,
SRGB8_ALPHA8_EXT : 35907,
...
2
votes
1
answer
3k
views
Is there a way to test the GLSL-ES version in the shader?
In web tools such as shadertoy, my fragment shader source is included in a main() I don't control or see. It would be the same if I were distributing some GLSL library.
My problem is ensuring ...
0
votes
1
answer
445
views
Using gl_FragData[] from multiple shader files
I have a webgl shader set up with some shaders. I'm using multiple render targets (gl_FragData[])
In the first shader, I can output to
gl_FragData[0] = vec4(..);
gl_FragData[1] = vec4(..);
...
5
votes
2
answers
9k
views
How to set Transparency properly in webgl
I am new to graphics and webgl. i am facing problem in setting proper transparency for the model in webgl 1.0.
Model contains more than one part (geometry).
shader code is
"if (usetransparency > ...
1
vote
0
answers
835
views
WebGL textureCubeLod causes seams on chrome/safari and not on ios
I'm working on the Image Based Lighting portion of a PBR shader in three.js. I'm using a .dds cubemap texture, brought in through DDSLoader.
I'm getting terrible seams in the lower lods on chrome and ...
0
votes
1
answer
4k
views
How to use the OES_texture_float extension? and create a texture as a floating point one for that?
How to use the OES_texture_float extension?
and create a texture as a floating point one for that?
As webGL 1 extension lists:
var ext = gl.getExtension("OES_texture_float");
var linear = gl....
7
votes
3
answers
5k
views
What is the difference between a ND-Buffer and a G-Buffer?
I'm noob at WebGL. I read in several posts of ND-Buffers and G-Buffers as if it were a strategic choice for WebGL development.
How are ND-Buffers and G-Buffers related to rendering pipelines? Are ND-...
0
votes
1
answer
225
views
What is the differences between render buffer object and depth texture via WEBGL_depth_texture?
In the environment I can use the extension WEBGL_depth_texture, I guess there is no use of render buffer object(RBO).
The depth texture is more convenient rather than using RBO since I can use it as ...
5
votes
2
answers
979
views
readPixels on multiple draw buffers in WebGL
I made a framebuffer object using the webgl_draw_buffers extension in order to provide three color buffers:
colorBuffer0 = gl.createRenderbuffer();
gl.bindRenderbuffer(gl.RENDERBUFFER, ...
0
votes
1
answer
245
views
Errors on phong shading (over texture) implementation in my shaders
I am trying to learn webGL, tried to implemement phong shading following this sample code on the link http://voxelent.com/html/beginners-guide/chapter_3/ch3_Sphere_Phong.html
I get two errors on ...
2
votes
1
answer
4k
views
Drawing multiple objects in webgl
I am WebGL beginner and trying to draw multiple objects, I have already rendered one, now going for multiple.
There are very less tutorial for multiple object rendering, the one that i could find was ...
3
votes
2
answers
4k
views
How can we have display of same objects in two canvas in webgl?
I am under a situation that i have two canvas, and i want to display the same object in both canvas (in fact i have to display different objects in each canvas, but i want to start by showing same ...
16
votes
1
answer
4k
views
How do you convert to half floats in JavaScript?
I want to be able to use the OES_texture_half_float extension in WebGL and provide my own data but there's no Float16Array in JavaScript. So how do I generate half float data?
0
votes
1
answer
2k
views
OES_texture_float extension use
How to use the OES_texture_float extension?
I do not understand that it is necessary to specify the arguments the function texImage2D.
var fb=gl.createFramebuffer();
gl.bindFramebuffer(gl.FRAMEBUFFER,...
0
votes
1
answer
1k
views
What are Privileged Extensions in WebGL?
I recently came across a graphics intensive page and wanted to use my Nvidia card (and not the inbuilt Intel) to render it. Upon looking for how to do that, one of the things I was required to do was ...
2
votes
0
answers
1k
views
WebGL OES_texture_float_linear android devices - Chrome
using threejs to create a sphere with texture.
in Chrome (41.0.) on Samsung Tab 4 (Android 4.4.2) I am getting the following console:
THREE.WebGLRenderer: OES_texture_float_linear extension not ...
0
votes
1
answer
6k
views
Three.js Error creating WebGL context
Friends, I need your help, the following code in three.js, all return null in this line:
_context || _canvas.getContext( 'webgl', attributes ) || _canvas.getContext( 'experimental-webgl', attributes )...
2
votes
0
answers
1k
views
mat3 attribute in WebGL
I'm attempting to use the ANGLE_instanced_arrays extension in WebGL to render multiple instances of an object with different mat3 transformation matrices. This is the code related to the buffer for my ...
2
votes
1
answer
898
views
WebGL performance problems with a >65k vertex mesh on a MacBook Pro
The following model has good performance on several low-end machines:
http://examples.x3dom.org/example/x3dom_sofaGirl.html
However on a MacBook Pro with Nvidia GT 650m the framerate is very low. I ...
3
votes
1
answer
6k
views
WebGL FrameBuffer - Render Depth Texture
I am in the process of integrating post processing effects into my 3D engine. I have hit a roadblock with capturing depth data using a FrameBuffer Object with WebGL. There has been no issue capturing ...
1
vote
2
answers
2k
views
Loading PNG images but using them as COMPRESSED_RGBA_S3TC_DXT5_EXT in WebGL?
I'm trying to load images in WebGL, and then uploading them to the GPU. I'd like to use a compressed texture format, even though the original images are uncompressed/lossless.
To upload, this is what ...
1
vote
2
answers
4k
views
WebGL copy texture framebuffer to texture framebuffer?
I am trying to copy a texture framebuffer to another one in WebGL, and so far it just gives an black screen. I am able to render in the texture framebuffer without problems.
Here is the code I ...
0
votes
2
answers
2k
views
WEBGL_draw_buffers not supported on chrome 37
I have trouble getting the webgl extension WEBGL_draw_buffers on chrome. My GPU should definitely support multiple draw buffers, Firefox supports the extension, but Chrome does not list it. Is there ...
1
vote
0
answers
843
views
Shadow mapping in WebGL without WEBGL_depth_texture on Android devices?
I wrote a web application that draws an interactive scene, including shadow mapping, using JavaScript and WebGL. I'd like to make sure that this site works on as many Android devices as reasonably ...
0
votes
1
answer
545
views
Why extension list is different when running in WebGL inspector?
Here is the list of GL extensions I get when I run my WebGL project:
GL_WEBKIT_WEBGL_compressed_texture_s3tc
WEBKIT_EXT_texture_filter_anisotropic
OES_texture_float_linear
...
5
votes
1
answer
5k
views
Does Three.js support OES_texture_float?
I want to render position or depth to a floating texture.
I use
vsnTexture = new THREE.WebGLRenderTarget(window.innerWidth, window.innerHeight,
{ minFilter: THREE.NearestFilter, ...
2
votes
2
answers
2k
views
Determine internal format of given astc compressed image through its header?
I am writing a EbGL based HTML application that uses ASTC (Adaptive Scalable Texture Compression) compressed textures to be loaded on my triangle. I would like to know that does there exists a way to ...
2
votes
1
answer
4k
views
Required WebGL extensions detection
I am working on a WebGL (using ThreeJs) application that, obviously, shows 3D models, and we are using some effects (shaders), looking to make a test to know whether the user can run the app or not, I ...
0
votes
2
answers
57
views
PhiloGL -> propagate transformation between models
I have a scene showing one object in multiple models. Each model displays the object at a variable state.
There's a slider to switch between multiple models.
My problem is that when the user rotates ...
2
votes
1
answer
153
views
load / remove multiple models in PhiloGL - WebGL
I am trying to load & remove models from the main webgl view with philoGL.
In the original script I found the place where one model is loaded.
However, I want to remove the first model and ...
0
votes
0
answers
89
views
WebGL - Width, height parameters passed in validateCompressedTexSubDimensions() function?
I am working on some compression support in WebGL-Webkit. So I was looking at existing S3TC support provided in WebGLRenderingContext.cpp file in Webkit code. What confuses me is the code written ...