Possible OpenGL bug /w ofSetLineWidth() and setStrokeWidth()

So I’m working on this polygon API for my videoclips and somehow when I choose to use ofCreateWindow(ofGLFWWindowSettings) instead of the simpler ofSetupOpenGL() in main() to set op my OpenGL window al LineWidth calls don’t work. It just doesn’t get rendered. (I need the explicit GL settings for using shaders)

I’ve been testing this out for weeks now. Using ofPolyline in combination with ofSetLineWidth() and ofPath::setStrokeWidth().

I’m on 0.9.8 from the main oF site. Tested on MacOS and Debian Linux. Did I miss something or is this some bug somewhere?


yes glLineWidth is not supported anymore in opengl 3 or more so any calls related to setting line width won’t work if you use that. there’s plans to have a shader internally in OF to somehow draw thick lines with proper caps… but it’s not there yet so you would need to draw thick lines by your self. if you look here in the forum for thick lines it’s something that a lot of people have encountered before and solved one way or another

Hi @arturo, thanks for your clear reply. Somehow I haven’t been able to find my answer on these forums. Also in the oF source there’s no mention of it being deprecated since OpenGL 3.

Anyway, as for me. I’ll be delving into shaders fulltime in the next year. So hopefully all my thick lines will be found there.