1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-03 17:56:21 +03:00
occt/tests/opengl/data/textures/cubemap_jpg
kgv 633084b809 0032862: Visualization, Graphic3d_TextureMap - add 3D texture definition
Image_PixMap has been extended to support definition of 3D bitmap (as an array of 2D slices).

Graphic3d_TypeOfTexture enumeration values have been renamed to include full enum prefix.
Added Graphic3d_TypeOfTexture_3D redirecting to GL_TEXTURE_3D.
OpenGl_Texture::Init() has been extended to allow initialization of 3D texture.

Graphic3d_Texture2Dmanual merged into Graphic3d_Texture2D and marked as deprecated alias.
Graphic3d_TOT_2D_MIPMAP has been deprecated in favor of dedicated Graphic3d_TextureRoot::SetMipMaps().

Added Graphic3d_Texture3D class.
vtexture - added argument -3d for uploading 3D texture.
2022-03-05 17:31:39 +03:00

24 lines
903 B
Plaintext

puts "============"
puts "0030807: Visualization, TKOpenGl - supporting cubemaps"
puts "Test multi-image cubemap"
puts "============"
puts ""
set aCubeMap_posx [locate_data_file SF_CubeMap_posx.jpg]
set aCubeMap_negx [locate_data_file SF_CubeMap_negx.jpg]
set aCubeMap_posy [locate_data_file SF_CubeMap_posy.jpg]
set aCubeMap_negy [locate_data_file SF_CubeMap_negy.jpg]
set aCubeMap_posz [locate_data_file SF_CubeMap_posz.jpg]
set aCubeMap_negz [locate_data_file SF_CubeMap_negz.jpg]
pload MODELING VISUALIZATION
vclear
vinit v -w 512 -h 512
vcamera -fovy 100
if { [checkplatform -windows] && [vdriver -default] == "TKOpenGles" } {
# Mipmaps cannot be generated for GL_SRGB8 texture format
}
vbackground -cubemap $aCubeMap_posx $aCubeMap_negx $aCubeMap_posy $aCubeMap_negy $aCubeMap_posz $aCubeMap_negz
foreach {i} { front back top bottom left right } { v$i; vdump $imagedir/${casename}_${i}.png }