- Adjusted Material/Texture/Lighting outline.
This commit is contained in:
@@ -57,7 +57,7 @@ struct Object
|
||||
{
|
||||
vec3 location, scale; // A matrix would be 64 bytes, this is instead 28 bytes
|
||||
quat rotation;
|
||||
uint32 material, lighting;
|
||||
uint32 lighting;
|
||||
}
|
||||
```
|
||||
|
||||
@@ -68,42 +68,6 @@ Objects are identified with a manually provided type and ID. Object types includ
|
||||
|
||||
A user should never have to specify these and should be automatically generated by the respective components.
|
||||
|
||||
Textures for 3D rendering are stored in various buffers with sizes of powers of 2. Ratios of `1:1`
|
||||
`2:1`, and `4:1` are allowed. The `2:1` ratio is specifically for spherical and cylindrical projection. UVs
|
||||
may be transformed to use a `2:1` as if it were `1:2`. Same applies for `4:1`
|
||||
Cubemaps and 3D textures may only be `1:1`.
|
||||
|
||||
- 8-Bit R Texture `4096, 2048, 1024, 512` (8)
|
||||
- 8-Bit RG Texture `4096, 2048, 1024, 512` (8)
|
||||
- 8-Bit RGB Texture `4096, 2048, 1024, 512` (8)
|
||||
- 8-Bit RGBA Texture `4096, 2048, 1024, 512` (8)
|
||||
- 8-Bit R Cubemap `1024, 512, 256, 128` (4)
|
||||
- 8-Bit RGB Cubemap `1024, 512, 256, 128` (4)
|
||||
|
||||
* 16-Bit HDR R Texture `4096, 2048, 1024, 512` (8)
|
||||
* 16-Bit HDR RGB Texture `4096, 2048, 1024, 512` (8)
|
||||
* 16-Bit HDR RGBA Texture `4096, 2048, 1024, 512` (8)
|
||||
* 16-Bit HDR R Cubemap `1024, 512, 256, 128` (4)
|
||||
* 16-Bit HDR RGB Cubemap `1024, 512, 256, 128` (4)
|
||||
|
||||
- 16-Bit Shadow Texture `4096, 2048, 1024, 512` (8)
|
||||
- 16-Bit Shadow Cubemap `2048, 1024, 512, 256` (4)
|
||||
|
||||
* 8-Bit 3D R Texture `256, 128, 64, 32` (4)
|
||||
* 8-Bit 3D RGB Texture `256, 128, 64, 32` (4)
|
||||
* 16-Bit 3D HDR R Texture `256, 128, 64, 32` (4)
|
||||
* 16-Bit 3D HDR RGB Texture `256, 128, 64, 32` (4)
|
||||
|
||||
Documentation should provide guidelines on categories of Art Assets and the resolution of textures to use.
|
||||
|
||||
Textures are identified by a 32-bit integer.
|
||||
- `8 bits` → the texture buffer
|
||||
- `24 bits` → the layer in the buffer
|
||||
|
||||
Artists should be informed on the texture structure of the engine and its limitations.
|
||||
However, these principles should be followed in other game engines as these are
|
||||
guided by what is most efficient for typical GPU hardware.
|
||||
|
||||
|
||||
Materials are, for the most part, user-defined. Documentation should make the user aware of this.
|
||||
Material buffers will be a sequence of the Material Struct instances.
|
||||
@@ -118,6 +82,28 @@ Types of materials:
|
||||
- Post-Process
|
||||
|
||||
|
||||
Each Material will have a buffer of Objects so that
|
||||
each can be rendered in a single draw call.
|
||||
|
||||
|
||||
## Lighting
|
||||
|
||||
When Dynamic Lighting is enabled, each light has two textures,
|
||||
one for static lighting and one for dynamic lighting.
|
||||
|
||||
|
||||
Shadows
|
||||
|
||||
- Directional Light → 16-bit Shadow Texture `4096`
|
||||
- Spotlights → 16-bit Shadow Texture `2048`
|
||||
- Point Lights → 16-bit Shadow Cubemap `1024`
|
||||
- Area Lights → 16-bit Shadow Texture `2048`
|
||||
|
||||
|
||||
Reflections
|
||||
|
||||
- Light Probe → 16-bit RGB Cubemap `512, 256`
|
||||
|
||||
|
||||
## Stages
|
||||
|
||||
|
||||
Reference in New Issue
Block a user