BabylonJS / BabylonJS/BabylonNative

Handle Engine States in Babylon Native

Open
#1,106 1 comment 0 reactions 0 assignees View on GitHub
rendering
Dominant language
C++
Stars
919
Forks
162
Avg merge
1d 15h
Merged PRs (30d)
19

Description

Currently, NativeEngine.js does not support changing and relying on states through the available state properties:

```
/**
* Gets the depth culling state manager
*/
public get depthCullingState(): DepthCullingState {
return this._depthCullingState;
}

/**
* Gets the alpha state manager
*/
public get alphaState(): AlphaState {
return this._alphaState;
}

/**
* Gets the stencil state manager
*/
public get stencilState(): StencilState {
return this._stencilState;
}

/**
* Gets the stencil state composer
*/
public get stencilStateComposer(): StencilStateComposer {
return this._stencilStateComposer;
}
```

Those are only working in WebGL and WebGPU. In Native state changes needs to flow through the old APIs dedicated functions like:
`setState`, `setDepthBuffer` and similar...

It is the source of both potential bugs (even in our current version) and forces ThinEngine to be bigger than required.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.