The current 3D states management for texture is quite problematic. The texture states in set at the beginning for the 2D to 3D state switch. It is better to follow the approach of es2 pipe where the texture states is set when a texture object is used.
See D3DContext.cc :
setDeviceParametersFor3D() {
...
// Set texture unit 0 to its default texture addressing mode for Prism
SUCCEEDED(res = pd3dDevice->SetSamplerState(0, D3DSAMP_ADDRESSU, D3DTADDRESS_WRAP)) &&
SUCCEEDED(res = pd3dDevice->SetSamplerState(0, D3DSAMP_ADDRESSV, D3DTADDRESS_WRAP)) &&
// Set texture filter to bilinear for 3D rendering
SUCCEEDED(res = pd3dDevice->SetSamplerState(0, D3DSAMP_MAGFILTER, D3DTEXF_LINEAR)) &&
SUCCEEDED(res = pd3dDevice->SetSamplerState(0, D3DSAMP_MINFILTER, D3DTEXF_LINEAR));
See D3DContext.cc :
setDeviceParametersFor3D() {
...
// Set texture unit 0 to its default texture addressing mode for Prism
SUCCEEDED(res = pd3dDevice->SetSamplerState(0, D3DSAMP_ADDRESSU, D3DTADDRESS_WRAP)) &&
SUCCEEDED(res = pd3dDevice->SetSamplerState(0, D3DSAMP_ADDRESSV, D3DTADDRESS_WRAP)) &&
// Set texture filter to bilinear for 3D rendering
SUCCEEDED(res = pd3dDevice->SetSamplerState(0, D3DSAMP_MAGFILTER, D3DTEXF_LINEAR)) &&
SUCCEEDED(res = pd3dDevice->SetSamplerState(0, D3DSAMP_MINFILTER, D3DTEXF_LINEAR));
- blocks
-
JDK-8324594 Add filtering modes to 3D textures
- Open
- relates to
-
JDK-8116785 Using selfIlluminationMap blurs texture
- Resolved
-
JDK-8124444 MeshView textures are not repeated
- Resolved
-
JDK-8123294 Adding a Button to 3D scene breaks lights calculations in D3D pipeline
- Closed
- links to
-
Review openjdk/jfx/1281