File tree Expand file tree Collapse file tree 2 files changed +3
-5
lines changed
resources/shaders/legacy/point Expand file tree Collapse file tree 2 files changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -60,25 +60,20 @@ bool Functions::tryEnableMultisampling(const int requestedSamples)
6060 if (hasMultisampling && requestedSamples > 0 ) {
6161 Base::glEnable (GL_MULTISAMPLE);
6262
63- // Base::glEnable(GL_POINT_SMOOTH);
6463 Base::glEnable (GL_LINE_SMOOTH);
6564 Base::glDisable (GL_POLYGON_SMOOTH);
66- // Base::glHint(GL_POINT_SMOOTH_HINT, GL_NICEST);
6765 Base::glHint (GL_LINE_SMOOTH_HINT, GL_NICEST);
6866
6967 return true ;
7068 } else {
7169 // NOTE: Currently we can use OpenGL 2.1 to fake multisampling with point/line/polygon smoothing.
7270 // TODO: We can use OpenGL 3.x FBOs to do multisampling even if the default framebuffer doesn't support it.
7371 if (requestedSamples > 0 ) {
74- // Base::glEnable(GL_POINT_SMOOTH);
7572 Base::glEnable (GL_LINE_SMOOTH);
7673 Base::glDisable (GL_POLYGON_SMOOTH);
77- // Base::glHint(GL_POINT_SMOOTH_HINT, GL_NICEST);
7874 Base::glHint (GL_LINE_SMOOTH_HINT, GL_NICEST);
7975 return true ;
8076 } else {
81- // Base::glDisable(GL_POINT_SMOOTH);
8277 Base::glDisable (GL_LINE_SMOOTH);
8378 Base::glDisable (GL_POLYGON_SMOOTH);
8479 return false ;
Original file line number Diff line number Diff line change @@ -9,5 +9,8 @@ out vec4 vFragmentColor;
99
1010void main()
1111{
12+ if (dot (gl_PointCoord - 0.5 , gl_PointCoord - 0.5 ) > 0.25 ) {
13+ discard ;
14+ }
1215 vFragmentColor = vColor * uColor;
1316}
You can’t perform that action at this time.
0 commit comments