Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

shader model info #114

Open
Jakey757 opened this issue Jun 6, 2021 · 0 comments
Open

shader model info #114

Jakey757 opened this issue Jun 6, 2021 · 0 comments
Labels
content Written content required for the wiki

Comments

@Jakey757
Copy link

Jakey757 commented Jun 6, 2021

shader model full

I think animation period, phase, and scale should be thought of like a graph. Period should be the base length of the graph, phase would shift the values in the graph left or right and scale would repeat the length of the period or cut it short. Animation function would simply change the shape of the graph.

Perpendicular and parallel angles used for reflections create a fresnel effect.
image
The orange in this example being the perpendicular and the green being parallel

I couldnt fit it in the first image but detail map scale applies after the shader UV map scale.

Rotation animation centers are based off of the UV scale in the gbxmodel/model tag
image
In this example for a animation function of zero you would have to use 1.00023 for x and 1 for y. For the cyborg gbxmodel you would use 0.5 for both as the base map UV scale is 1.

Alpha test vs alpha blended decal
image
By default shader model uses alpha test which treats alpha transparency as 1 bit alpha, this creates aliasing and hard edges but sorts much better with other transparent surfaces. The alpha blended decal flag forces shader model to use alpha blend which is the default transparent shaders like chicago uses, alphas are in 8 bit and this provides very smooth transparency but at the cost of sorting terribly against other transparent surfaces, for this reason its relegated to decal like shaders where they are against solid objects.

Radiosity note: If detail level is set too high, the mesh the shader is on could attempt to subdivide too much and fail to render lightmaps. Some maps will fail to render lightmaps even with original shaders because these had to be changed on a per scenario basis. (irrelvant to shader model but its part of the tag so i thought i'd add it)

Self illumination color lower and upper bounds are interpolated between linearly with the animation function. Setting a color source can allow you to set the lower and upper bounds in the object itself and choose to use the flags to change the interpolation.

Change color channel source C will have it's color values overwritten if the scenario is multiplayer, with the hardcoded colors. If the channel source is A, it will be overwritten by actor variant color values if spawned as an ai (this one i haven't proven yet, it just seems to follow some kind of convention bungie used).

For detail map functions
double biased multiply: double multiply the detail map with the diffuse map, brightens the detail map before multiplying (standard setting, detail maps with grey backgrounds and black details)
multiply: multiply the detail map with the diffuse map (white backgrounds and grey-black details)
add: add the detail map to the diffuse map (useful for detail maps with light colors. black backgrounds and light details)

Base map attributes for shader model
The RGB is treated as diffuse color, alpha is treated as transparency. Halo predates physically based rendering, so lighting and shadows are typically baked or authored into the base map.

Ending thoughts
Maybe get actual image examples from halo itself if they can be used.

@csauve csauve added the content Written content required for the wiki label Jun 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
content Written content required for the wiki
Development

No branches or pull requests

2 participants