Jump to content
Sign in to follow this  
Fandore

Using directX9 shaders properly

Recommended Posts

Hello Community, I need some help understanding how to use the DirectX9 shader. there is an image below. the Yellow box is what I need help with and am completely lost at. The Red Elliptical is the two textures being used as shown to the right. the Red circle is where the textures are suppose to be applied. as far as i can understand, the base texture is suppose to be played on a loop aka a scroll map in conjunction with the scroll map (the first texture shown) and the light (the second texture shown) is suppose to be what is used.

 

post-10276-0-66549100-1437284251_thumb.jpg

my complete lack of knowledge when it comes to Basic shaders is what is holding me back, if anyone could

A, directly help me in this endeavor to help me understand this better, it would be highly appreciated, aka short skype chat.

B, link some information on how to use the shader properly and explain its workings so i can gain perspective.



Either would help tremendously and would be highly needed to push this project back into full development.

Thank you for you're time sincerely Fandore.

Edited by Fandore

Share this post


Link to post

The parameters of the screenshot:

Directional Light/Point Light: it's only for Max to give a view that resembles more what you see ingame, it's just the light sources used.

Ambient Material Color: Also only for Max, ingame it depends on the map setting. This color is added onto everything else.

Diffuse Material Color: A multiplier for the diffuse texture.

Specular Material Color: Also Max only. It simulates the color of the light source.

Specular Shininess: The exponent for the specular function, higher values give a more defined light reflection, lower values result in a more diffuse material.

Emissive Material Color: This is the color which the object emits on its own without the need of a light source.

Opacity: Opacity obviously.

Edge fade out: higher values let the object fade out at the edges.

Number of Textures to use: 1 or 2.

Base Texture: The base diffuse Texture that is applied onto the object.

Secondary Texture: Only used if the Number of Textures to use is set to 2. Applies a second texture to the model depending on the settings below.

Allow House Color: If the object should be recolored in the player's color.

Preview House Color Enable: Max only, enables the preview in Max how it would look like ingame with the above setting set to true.

Preview House Color: Max only, the color to preview.

Depth Write Enable: If objects rendered after this one should depth test against this or the object behind it.

Alpha Text Enable: If the objects alpha should be used for alpha testing. 1 is opaque, <1 is invisible.

Culling Enable: If the object should cull stuff that's behind it (usually unset for transparent objects).

Blend mode: Opaque, obviously opaque. Alpha, uses the alpha of the base texture (or Secondary Texture if func is set to 3) for blending it with the background. Additive, adds the RBG values to the background.

Sec texture func: Mul, multiplier. Mulx2, doubles the values and multiplies then. Alph, as the source for the alpha. 4 can't read and no time to check.

TexMapper0: How the Base Texture is applied. Direct, Scl/move: scale or move, Video: divides the texture in equal chunks to be displayed like a video.

UV0 Scl/Move: If TexMapper0 is set to 2: rg is xy scale, ba is xy move

UV0 Video Tex: Fps and number of textures.

TexMapper1: How the Secondary Texture is applied. Direct, Scl/move: scale or move.

UV1 Scl/Move: If TexMapper1 is set to 2: rg is xy scale, ba is xy move

UV0 Clmp/Mip: Base Texture XY clamping and mipmap settings, no need to set this.

UV0 Clmp/Mip: Secondary Texture XY clamping and mipmap settings, no need to set this.

Share this post


Link to post

Hey Lauren,

Thanks for your initial insights.

Do you think you, or another person who knows this topic could spare some time to sit down on skype to help teach fir a little bit?

Forgive me if it's out of place, but Fandore says he's willing to financially compensate you for your time, not sure if that is an appropriate thing in this instance.

 

It's just, that this is the last part of the puzzle, according to him, and he's really eager to get this down, so we can continue our consistent level of content.

I tried pming you, and adding you on skype, but no response yet.

Thanks in advance.

-Jist

Edited by GeneralJist

Share this post


Link to post

it took me time to figure this one out, i got it down though, i went back and looked into the viewer and found the settings, i messed around with them till i got it and figured out how to make the shaders right.

Share this post


Link to post

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.

×