Cam simulator feature update (#15597)
* remove redundant code * Improve lighting, add ambient occlusion * Add cleanup code. Dialog is now deleted when cloesd. * change back to ambient occlusion * Fix G8x drill sequence bug. issue #14369 * fix bad simulation artifacts under Linux and QT. Issue #14369 * fix merge issue * fix border artifact on buttons * support showing path lines. revise the gui. * add option for arbitrary solids. wip * use vectors instead of mallocs * Handle arbitrary stock shapes + show base shape. * Complete the base shape display feature. eliminate co-planar artifacts. * support window scaling. upstream issue #14334 * Apply lint fixes * some missing lints. * Attend pylint issues * Apply code fixes based on @kadet1090 review * fix some clang-tidy warnings. * CAM: Linter cleanup round 1 --------- Co-authored-by: Chris Hennes <chennes@gmail.com>
This commit is contained in:
@@ -27,11 +27,17 @@ namespace MillSim
|
||||
{
|
||||
Texture::~Texture()
|
||||
{
|
||||
glDeleteTextures(1, &mTextureId);
|
||||
DestroyTexture();
|
||||
}
|
||||
|
||||
void Texture::DestroyTexture()
|
||||
{
|
||||
GLDELETE_TEXTURE(mTextureId);
|
||||
}
|
||||
|
||||
bool Texture::LoadImage(unsigned int* image, int _width, int _height)
|
||||
{
|
||||
DestroyTexture();
|
||||
width = _width;
|
||||
height = _height;
|
||||
glGenTextures(1, &mTextureId);
|
||||
@@ -58,4 +64,4 @@ bool Texture::unbind()
|
||||
return true;
|
||||
}
|
||||
|
||||
} // namespace MillSim
|
||||
} // namespace MillSim
|
||||
|
||||
Reference in New Issue
Block a user