bluecadet / Cinder-BluecadetViews

Scene graph Cinder block with touch management and various tools for UI dev
MIT License
11 stars 3 forks source link

LineView doesn't change size based on ScreenCamera zoom #139

Closed adielfernandez closed 5 years ago

adielfernandez commented 5 years ago

It works if you add in the ScreenCamera scaling to the linewidth:

LineView.cpp:
    float screenScale = bluecadet::core::ScreenCamera::getInstance()->getScale().x;
    gl::ScopedLineWidth lineWidth(mLineWidth * screenScale);

Only works up to GLSL's maximum line width, but this should be good enough. If fatter lines are needed, just draw Rect. @benjaminbojko if this looks good to you I have a pull request ready to fold it in.

benjaminbojko commented 5 years ago

Looks good, thanks

benjaminbojko commented 5 years ago

Closed in #140