1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-29 14:00:49 +03:00

0028912: Visualization, TKOpenGl - multi-texture support

Graphic3d_AspectFillArea3d now stores array of textures.
Graphic3d_TextureParams stores texture unit for mapping texture.

OpenGl_Context::BindTextures() - context now manages the set of active textures.
Related code has been removed from OpenGl_Workspace.

OpenGl_Sampler has been extended to hold texture parameters structure.
OpenGl_Texture now holds OpenGl_Sampler instance as class field.
OpenGl_Texture inherits new class OpenGl_NamedResource and holds
texture identifier used for sharing resource in OpenGl_Context.

OpenGl_RaytraceGeometry now creates bindless textures taking
Sampler object directly from OpenGl_Texture.
OpenGl_Context::BindTextures() automatically recreates immutable
Sampler Object on texture parameters change.

Declared new structure OpenGl_ArbSamplerObject for platform-neutral
usage of related functionality.
Related functions are now loaded within OpenGL ES 3.0+.

Declarations.glsl - occActiveSampler has been renamed to occSampler0
with aliases occSamplerBaseColor (main) and occActiveSampler (for compatibility).
Additional texture samplers should be declared explicitly
within specific GLSL program as occSampler1, occSampler2, etc.

AIS_Shape and AIS_ColoredShape now computes Shaded presentation
with UV coordinates if texture mapping is enabled in Drawer.

vshaderprog now accepts Shader source code as parameter.
This commit is contained in:
kgv
2017-07-10 15:43:25 +03:00
committed by bugmaster
parent a6dee93dfa
commit cc8cbabe5c
59 changed files with 2095 additions and 1272 deletions

View File

@@ -2,6 +2,7 @@ glext.h
OpenGl_ArbDbg.hxx
OpenGl_ArbFBO.hxx
OpenGl_ArbIns.hxx
OpenGl_ArbSamplerObject.hxx
OpenGl_ArbTBO.hxx
OpenGl_ArbTexBindless.hxx
OpenGl_AspectFace.cxx
@@ -50,8 +51,11 @@ OpenGl_FrameBuffer.hxx
OpenGl_FrameBuffer.cxx
OpenGl_Texture.cxx
OpenGl_Texture.hxx
OpenGl_TextureSet.cxx
OpenGl_TextureSet.hxx
OpenGl_Resource.hxx
OpenGl_Resource.cxx
OpenGl_NamedResource.hxx
OpenGl_Font.hxx
OpenGl_Font.cxx
OpenGl_BackgroundArray.cxx