Increase max textures from 8.
-
- Competition winner
- Posts: 523
- Joined: Tue Jan 15, 2013 6:36 pm
Increase max textures from 8.
I'm using direct3d9 driver and I have a shader which use's some textures for details and other things but I'm only limited to 8 I tried changing it in the irrlicht config file from 8 to say 9 and recompiled which would be fine for my purposes but irrlicht ignores the last texture after 8. Have I done anything wrong?
Re: Increase max textures from 8.
Perhaps DX9 or your card (in DX9 mode) does not support more than 8 textures?
-
- Competition winner
- Posts: 523
- Joined: Tue Jan 15, 2013 6:36 pm
Re: Increase max textures from 8.
Makes sense.
Re: Increase max textures from 8.
Why don't you combine all textures onto one. Then you can have many.
Regards
Regards
Re: Increase max textures from 8.
you have <<_IRR_MATERIAL_MAX_TEXTURES_ 8>> defined in IrrCompileConfg.h
you must change E_TRANSFORMATION_STATE enumeration to add more texture matrix
else the engine iterator over an out-of-bound array of "irr::core::matrix4" if I remember (in 1.
http://irrlicht.sourceforge.net/forum/v ... =2&t=46838
since I use a mix of glsl and sampler2DArray (better performance, "less" transformation matrix)
you must change E_TRANSFORMATION_STATE enumeration to add more texture matrix
else the engine iterator over an out-of-bound array of "irr::core::matrix4" if I remember (in 1.
http://irrlicht.sourceforge.net/forum/v ... =2&t=46838
since I use a mix of glsl and sampler2DArray (better performance, "less" transformation matrix)
-
- Competition winner
- Posts: 523
- Joined: Tue Jan 15, 2013 6:36 pm
Re: Increase max textures from 8.
One solution I'm gonna try is vertex colors so I can remove the use of one texture being used as a mask. That should b sufficient enough for me.
Re: Increase max textures from 8.
In CD3D9Driver.cpp
the line 439 is
when it should be
line 457
should be
The caps viewer only report the fixed pipeline capability and not the shader one so those limits are invalid
Apparently all my attempts to get this bug fixed have failed to this day
the line 439 is
Code: Select all
MaxTextureUnits = core::min_((u32)Caps.MaxSimultaneousTextures, MATERIAL_MAX_TEXTURES);
Code: Select all
MaxTextureUnits = MATERIAL_MAX_TEXTURES;
Code: Select all
DriverAttributes->setAttribute("MaxSupportedTextures", (s32)Caps.MaxSimultaneousTextures);
Code: Select all
DriverAttributes->setAttribute("MaxSupportedTextures", (s32)MATERIAL_MAX_TEXTURES);
Apparently all my attempts to get this bug fixed have failed to this day
Re: Increase max textures from 8.
Hi,
I already sent a fix for this issue on SVN. At now it's possible to set up to 16 textures in D3D9 (I think that we should set 8/16 textures by default for v1.9).
Cheers,
I already sent a fix for this issue on SVN. At now it's possible to set up to 16 textures in D3D9 (I think that we should set 8/16 textures by default for v1.9).
Cheers,
Library helping with network requests, tasks management, logger etc in desktop and mobile apps: https://github.com/GrupaPracuj/hermes
Re: Increase max textures from 8.
Nice to hear we are finally getting 16 textures available for the materials
"There is nothing truly useless, it always serves as a bad example". Arthur A. Schmitt
-
- Competition winner
- Posts: 523
- Joined: Tue Jan 15, 2013 6:36 pm
Re: Increase max textures from 8.
Does this work for ShaderPipeline or just the trunk that has cubemap support?
Re: Increase max textures from 8.
Only trunk. Shader-pipeline is deprecated, I'll prepare new FVF branch soon, designed for D3D12/Vulkan requirments.
Library helping with network requests, tasks management, logger etc in desktop and mobile apps: https://github.com/GrupaPracuj/hermes
-
- Competition winner
- Posts: 523
- Joined: Tue Jan 15, 2013 6:36 pm
Re: Increase max textures from 8.
I only use ShaderPipeline for Hardware Skinning and custom vertex format, is this any reason to stick with it as it seems a lot of things have changed.
Re: Increase max textures from 8.
You shouldn't use shader-pipeline anymore and switch to trunk. When I'll release the new FVF branch most of your stuff from trunk will be working in that branch too (of course a stuff related to vertices handling will need slightly modifications).
Library helping with network requests, tasks management, logger etc in desktop and mobile apps: https://github.com/GrupaPracuj/hermes
Re: Increase max textures from 8.
Nadro some of us are stuck on the shader-pipeline branch because ou projects depends heavily on it's feature
-
- Competition winner
- Posts: 523
- Joined: Tue Jan 15, 2013 6:36 pm
Re: Increase max textures from 8.
I agree with Granyte I worked out all the issues with Hardware skinning and my various shaders and when I gave the trunk a try I wasn't able to use HWS anymore, the other things I don't really mind. I really wanted to use cubemaps.