OpenGL multisampling feature on Windows is not working

I am using JUCE 5.2.1, and the OpenGL multisampling feature is not working on Windows, apparently in the file juce_OpenGL_win32.h, line 36:
NativeContext (Component& component,
const OpenGLPixelFormat& pixelFormat,
void* contextToShareWith,
bool /useMultisampling/,
OpenGLVersion)

“useMultisampling” parameter is commented out, my initialization code is:

openGLContext_.setComponentPaintingEnabled(true);
openGLContext_.setMultisamplingEnabled(true);
openGLContext_.setRenderer(this);
openGLContext_.setContinuousRepainting(false);
OpenGLPixelFormat pixelFmt(8, 8, 0, 0);
pixelFmt.multisamplingLevel = 128;
openGLContext_.setPixelFormat(pixelFmt);
openGLContext_.attachTo(*this);
this->setOpaque(false);

is there anyone helping me?

Thank you in advance.

Just found this post - it’s related to what I’m running into.

In your case, you can ignore the flag and just set the multisampling level by calling setPixelFormat on the context, and setting the multisampling level to whatever you want/whatever your hardware and driver support.