bgfx_encoder_set_state

Set render states for draw primitive. Remarks: 1. To setup more complex states use: BGFX_STATE_ALPHA_REF(_ref), BGFX_STATE_POINT_SIZE(_size), BGFX_STATE_BLEND_FUNC(_src, _dst), BGFX_STATE_BLEND_FUNC_SEPARATE(_srcRGB, _dstRGB, _srcA, _dstA), BGFX_STATE_BLEND_EQUATION(_equation), BGFX_STATE_BLEND_EQUATION_SEPARATE(_equationRGB, _equationA) 2. BGFX_STATE_BLEND_EQUATION_ADD is set when no other blend equation is specified.

  1. void bgfx_encoder_set_state(bgfx_encoder_t* _this, ulong _state, uint _rgba)
    version(BindBgfx_Static)
    extern (C) @nogc nothrow
    void
    bgfx_encoder_set_state
  2. da_bgfx_encoder_set_state bgfx_encoder_set_state;

Parameters

_state ulong

State flags. Default state for primitive type is triangles. See: BGFX_STATE_DEFAULT. - BGFX_STATE_DEPTH_TEST_* - Depth test function. - BGFX_STATE_BLEND_* - See remark 1 about BGFX_STATE_BLEND_FUNC. - BGFX_STATE_BLEND_EQUATION_* - See remark 2. - BGFX_STATE_CULL_* - Backface culling mode. - BGFX_STATE_WRITE_* - Enable R, G, B, A or Z write. - BGFX_STATE_MSAA - Enable hardware multisample antialiasing. - BGFX_STATE_PT_[TRISTRIP/LINES/POINTS] - Primitive type.

_rgba uint

Sets blend factor used by BGFX_STATE_BLEND_FACTOR and BGFX_STATE_BLEND_INV_FACTOR blend modes.

Meta