myvi icon indicating copy to clipboard operation
myvi copied to clipboard

blending problem

Open szabolcsdombi opened this issue 8 years ago • 8 comments

In some computer not looks well when set the blend.

I found this line in the README. I think I could solve this by adding a new feature to ModernGL. The default blending is (GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA)

What blending settings you may need?

szabolcsdombi avatar Oct 16 '17 06:10 szabolcsdombi

@cprogrammer1994 Thanks, See here, there is a tooth demo in ImagePy's page. It is draw by mayavi, I can't draw like this use moderngl, I think I should set some color mix mode, I have try some, but failed. And In some computer, I even cannot see the inner object through the blend surface.

and on mac, I got a shader error, not support 330 version.

yxdragon avatar Oct 16 '17 17:10 yxdragon

And In some computer, I even cannot see the inner object through the blend surface

Sounds like the absence of Transparency Sorting

szabolcsdombi avatar Oct 16 '17 20:10 szabolcsdombi

If transparency sorting does not help you, then help me understand what kind of blending do you need.

szabolcsdombi avatar Oct 16 '17 20:10 szabolcsdombi

if I put a ball in a transparent cube.

  1. in any computer and system, It looks bad in some specific view. (that should be the transparency sorting)

  2. on win10, 64bit, wx4.0, I cannot see the ball. (even set transparent to 0, the cube hide, and cannot see the ball)

  3. on mac, I got a shader error, not support version 330.

and the sorting work seems must be done on cpu, need I have wrote the sorting algrithsm? and give to the GPU as the right order? If it is hard, it is not nessesary. (vtk and mayavi has the same question)

some question may be wx's bug or system's support, I learn opengl just several days, So I cannot solve them, even donot known why it happends.

yxdragon avatar Oct 17 '17 04:10 yxdragon

  1. Can you paste the code here?
  2. Checkout this list is your Mac supporting OpenGL 3.3?

szabolcsdombi avatar Oct 17 '17 08:10 szabolcsdombi

Could the mac issue be as simple as needing to explicitly request the OpenGL Core Profile? This is sometimes necessary; see e.g. https://stackoverflow.com/questions/22926779/cannot-use-glsl-330-on-mac-mavericks and https://stackoverflow.com/questions/19865463/opengl-4-1-under-mavericks?lq=1

I'm not sure how to get ModernGL to do this.

ramcdougal avatar May 01 '18 03:05 ramcdougal

ModernGL detects the context created by the window. If a standalone context is requested then a core profile will be created.

szabolcsdombi avatar May 02 '18 05:05 szabolcsdombi

mayavi 中文介绍

image

QGB avatar Apr 24 '21 02:04 QGB