Questions tagged [webgl2]

WebGL 2 is the 2nd version of WebGL. It is based on OpenGL ES 3.0

Filter by
Sorted by
Tagged with
0 votes
0 answers
40 views

How to efficiently assign values (e.g. colours) to edges in WebGL

I'm working with 3D meshes (mostly triangle meshes, though occasionally quad- or general polygonal meshes) for which I compute a value for each edge. This value I'd like to visualise using a colour ...
  • 683
0 votes
0 answers
18 views

I am having trouble identifying where my performance issues are coming from

Here is a recording of a profiling session in Chrome. https://drive.google.com/file/d/18iXCmNzooNDZLAQVnjylwG0xkDvq6IAG/view In the recording, A 3d model is rotating, and our WebGL rendering engine is ...
1 vote
1 answer
81 views

problems using internal formats other than R8 for texture data

I'm using GLSL shaders with 3D texture data in WebGL2 code via TypeScript. My texture data contains single-channel samples, with different data sources using samples with different bit widths (u8, u16,...
0 votes
1 answer
64 views

timing webgl and webgl call sequentiality

Currently implementing a gpgpu sorter using webgl by rendering to textures. While I have a working sorter I am having difficulty comparing the times of its execution, especially to compare it with the ...
1 vote
1 answer
115 views

WebGL / How to remove the dark edges that appear on the border with the transparent part of the image after applying the warp effect?

Demo https://codepen.io/Andreslav/pen/wvmjzwe Scheme: Top left - the original. Top right - the result. Bottom right - rounding coordinates when extracting color. The problem can be solved this way, ...
1 vote
1 answer
52 views

How to get GLSL 300 es shaders running in PIXI.JS

I need to use functions such as textureSize() in my fragment shader, but they aren't available in GLSL 100, which is what PIXI defaults to. If I try to use them anyway i get an error: "...
  • 813
0 votes
0 answers
84 views

Chrome use swiftShader for ANGLE backend while firefox correctly use GPU on windows7

I'm using windows7 with the chrome and firefox up to date, and here is the result of site webglreport: I added '--use-angle=gl' to force chrome to support webgl2, but the CPU usage up to 100% when I ...
  • 38
0 votes
1 answer
66 views

Are there any major differences between webgl and webgl2 APIs?

I'm currently learning WebGL and I found out that there are actually 2 variants of this api -> webgl and webgl2. So I would say that webgl2 is a newer version of the api, therefore it would be ...
1 vote
1 answer
57 views

Migrating to WebGL2 shaders from WebGL

I am currently migrating some WebGL code to make use of WebGL2 shaders. I have altered the shaders to the es 300 syntax and systematically redacted the 3D engine business logic code to the point where ...
  • 1,038
0 votes
1 answer
46 views

WebGL objects not rendering properly when moving camera

I am trying to render a lot of objects. It worked fine on 1 object, just not on multiple. It is causing some of the vertices not to be rendered when looking around to the right of the camera: But ...
0 votes
2 answers
51 views

WebGL Textures are blurry, even with gl.NEAREST

I am trying to create a texture for an object, but it will appear blurry, whether I have gl.LINEAR or gl.NEAREST for my MAG and MIN filters Here is where I initialize my textures (By calling new ...
0 votes
1 answer
25 views

Does using a canvas element as texture source involve CPU/GPU sync and memory copy?

I have a HTMLCanvasElement with some pixels rendered on it. Now I want to upload its data to another framebuffer (via color attachment texture). gl.texImage2d(...otherArgs, canvasElement); I'm ...
0 votes
1 answer
58 views

TWGL Camera rotation not expected

I'm so confused, I am trying to use mouse and keyboard controls (With WebGL2), and I'm trying to rotate and move the camera with these four functions: m4.rotateX(m, angleInRadians, dst); m4.rotateY(m, ...
0 votes
0 answers
69 views

WebGL Unable to compile a basic vertex shader

I'm following Cherno's OpenGL course on YouTube, I think I have a case of code blindness since I cant see anything wrong with my program. Can someone help me out and tell me what I'm doing wrong or ...
1 vote
2 answers
58 views

Animate vertex positions with webgl2 transform feedback using two programs

I try to follow example from webgl2fundamentals regarding transform feedback. My goal is to create animation of vertex positions in a way that there are two programs: doing animation calculations ...
  • 1,084

15 30 50 per page
1
2 3 4 5
25