Jump to content
Eternal Lands Official Forums
Sign in to follow this  
Xaphier

Shader system demo

Recommended Posts

I made a demo (gltest.exe) so you can see some effects of the shader system. You can download every thing needed here http://www.eternal-lands.com/shaders_test.zip. Only the normal mapping, parallax mapping and the lava are eye candies. The program shows some materials with shaders. You need GL_ARB_fragment_shader, GL_ARB_shader_objects, GL_ARB_shading_language_100 and GL_ARB_vertex_shader or OpenGL 2.0 instead of all the extensions.

Materials:

  1. default: Nothing special, only for testing.
  2. stones: Nothing special, only for testing.
  3. stones_ext: Texture in YCrCb color space.
  4. stones_test: Nothing special, only for testing.
  5. door_ext: Texture in YCrCb color space.
  6. door: Nothing special, only for testing.
  7. door_dxt1: Nothing special, only for testing.
  8. m0: Nothing special, only for testing.
  9. m0_ext: Nothing special, only for testing.
  10. m0_dxt1: Nothing special, only for testing.
  11. dxt1: DXT1 compressed texture. Mainly for comparison with the YCoCg.
  12. dxt3: DXT3 compressed texture. Mainly for comparison with the YCoCg.
  13. dxt5: DXT5 compressed texture. Mainly for comparison with the YCoCg.
  14. YCoCg: This is an example of storing the texture in the YCoCg color space with DXT5 compression. Looks better than DXT1 compression but needs one byte per pixel. No special extension needed besides texture compression and shaders.
  15. rgb8: Uncompressed rgb8 texture. Mainly for comparison with the YCoCg.
  16. rgb16: Nothing special, only for testing.
  17. rgb16f: Half float point texture. Here you can see if your graphic card supports linear filtering for this type of texture format.
  18. rgb32f: Single float point texture. Here you can see if your graphic card supports linear filtering for this type of texture format.
  19. rgba8: Nothing special, only for testing.
  20. rgba4: Nothing special, only for testing.
  21. l8: Nothing special, only for testing.
  22. la8: Nothing special, only for testing.
  23. no_normal_mapping: Texture without normal mapping.
  24. normal_mapping: Texture with uncompressed tangent space normal mapping.
  25. normal_mapping_ext: Texture with compressed tangent space normal mapping. Supported are 3Dc, LATC2 and DXT5.
  26. parallax_mapping: Texture with tangent space normal mapping and parallax.
  27. gray: A shader that "grays" the texture like the texture adaption with night_shift_textures, but without the need to change the texture.
  28. lava: A lava shader. Simple, fast and nice looking.

with the parameter --start= and the name of the material you want to start with, e.g. --shart=lava begins with the lava material. Default is material default :confused:

The keys left and right are used to switch to the previous or next material.

 

The program tests runs 93 unit tests. With --show_progess=yes it shows progress. Don't show anything nice.

 

Source: http://www.eternal-lands.com/shader_system.tar.bz2

 

You need boost to compile it

Edited by Xaphier

Share this post


Link to post
Share on other sites

Wow,

Lava looks awsome, and also the stones are a mayor improvement...

 

The options: rgb16f and rgb32f didn't work as expected (flickering and CPU usage going through the roof)

 

will post my #GL_info if needed...

Share this post


Link to post
Share on other sites

Then there is something wrong.. i have the float and 1/2 float extensions

 

Video card: GeForce 6200 TurboCache/PCI/SSE2/3DNOW!

Vendor ID: NVIDIA Corporation

OpenGL Version: 2.1.1

 

Supported extensions:

GL_ARB_color_buffer_float

GL_ARB_depth_texture

GL_ARB_draw_buffers

GL_ARB_fragment_program

GL_ARB_fragment_program_shadow

GL_ARB_fragment_shader

GL_ARB_half_float_pixel

GL_ARB_imaging

GL_ARB_multisample

GL_ARB_multitexture

GL_ARB_occlusion_query

GL_ARB_pixel_buffer_object

GL_ARB_point_parameters

GL_ARB_point_sprite GL_ARB_shadow

GL_ARB_shader_objects

GL_ARB_shading_language_100

GL_ARB_texture_border_clamp

GL_ARB_texture_compression

GL_ARB_texture_cube_map

GL_ARB_texture_env_add

GL_ARB_texture_env_combine

GL_ARB_texture_env_dot3

GL_ARB_texture_float

GL_ARB_texture_mirrored_repeat

GL_ARB_texture_non_power_of_two

 

*more comes but not intresting*

Edited by RotationZ

Share this post


Link to post
Share on other sites

Oh, you use one of the lastes nvidia drivers? Then it is likely the bug in the drivers that also make problems with the FBO float point format tests.

Share this post


Link to post
Share on other sites

Other PC:

Here the RGB16F works, the RGB32F doesn't. again latest Nvidia drivers if you want i can switch to older ones:

 

Video card: GeForce 7300 GS/PCI/SSE2/3DNOW!

Vendor ID: NVIDIA Corporation

OpenGL Version: 2.1.1

 

Supported extensions:

GL_ARB_color_buffer_float

GL_ARB_depth_texture

GL_ARB_draw_buffers

GL_ARB_fragment_program

GL_ARB_fragment_program_shadow

GL_ARB_fragment_shader

GL_ARB_half_float_pixel

GL_ARB_imaging GL_ARB_multisample

GL_ARB_multitexture

GL_ARB_occlusion_query

GL_ARB_pixel_buffer_object

GL_ARB_point_parameters

GL_ARB_point_sprite

GL_ARB_shadow GL_ARB_shader_objects

GL_ARB_shading_language_100

GL_ARB_texture_border_clamp

GL_ARB_texture_float

GL_ARB_texture_mirrored_repeat

Edited by RotationZ

Share this post


Link to post
Share on other sites

I added the float point textures to the demo to detect errors in drivers etc. to prevent a big error search later. If you want you can downgrade the drivers, I think the previous version should work.

Share this post


Link to post
Share on other sites

Owkay will try...

 

Just found out that the current driver i'm using contains a flaw which was fixed recently by nvidia,

will update to the most current one first and try again...

 

*/ EDIT */

Latest drivers show no problems

Lava looks very realistic already.. awsome :confused:

Thanx nVidia

*/

Edited by RotationZ

Share this post


Link to post
Share on other sites

I used the older version: Nvidia Forceware 163.75

Nvidia brought an update of this driver because of various problems, concering the Geforce 7 range

So i downloaded the new version yesterday this is the most current version:

Nvidia Forceware 169.21 (Dated 10-12-07)

 

Both are the win32 drivers for windowsXP

Edited by RotationZ

Share this post


Link to post
Share on other sites

169.21 is the working one for RGB16F and RGB32F ....

 

the other version doesn't do the RGB32F, it does however show RGB16F correctly

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×