Updated bindings.

This commit is contained in:
Бранимир Караџић
2022-03-31 18:41:55 -07:00
parent f44818b548
commit eed8ed95dd
7 changed files with 351 additions and 340 deletions

View File

@@ -2490,7 +2490,7 @@ public static class bgfx
public static extern void init_ctor(Init* _init);
/// <summary>
/// Initialize bgfx library.
/// Initialize the bgfx library.
/// </summary>
///
/// <param name="_init">Initialization parameters. See: `bgfx::Init` for more info.</param>
@@ -2507,13 +2507,13 @@ public static class bgfx
/// <summary>
/// Reset graphic settings and back-buffer size.
/// @attention This call doesn't actually change window size, it just
/// resizes back-buffer. Windowing code has to change window size.
/// @attention This call doesnt change the window size, it just resizes
/// the back-buffer. Your windowing code controls the window size.
/// </summary>
///
/// <param name="_width">Back-buffer width.</param>
/// <param name="_height">Back-buffer height.</param>
/// <param name="_flags">See: `BGFX_RESET_*` for more info. - `BGFX_RESET_NONE` - No reset flags. - `BGFX_RESET_FULLSCREEN` - Not supported yet. - `BGFX_RESET_MSAA_X[2/4/8/16]` - Enable 2, 4, 8 or 16 x MSAA. - `BGFX_RESET_VSYNC` - Enable V-Sync. - `BGFX_RESET_MAXANISOTROPY` - Turn on/off max anisotropy. - `BGFX_RESET_CAPTURE` - Begin screen capture. - `BGFX_RESET_FLUSH_AFTER_RENDER` - Flush rendering after submitting to GPU. - `BGFX_RESET_FLIP_AFTER_RENDER` - This flag specifies where flip occurs. Default behaviour is that flip occurs before rendering new frame. This flag only has effect when `BGFX_CONFIG_MULTITHREADED=0`. - `BGFX_RESET_SRGB_BACKBUFFER` - Enable sRGB backbuffer.</param>
/// <param name="_flags">See: `BGFX_RESET_*` for more info. - `BGFX_RESET_NONE` - No reset flags. - `BGFX_RESET_FULLSCREEN` - Not supported yet. - `BGFX_RESET_MSAA_X[2/4/8/16]` - Enable 2, 4, 8 or 16 x MSAA. - `BGFX_RESET_VSYNC` - Enable V-Sync. - `BGFX_RESET_MAXANISOTROPY` - Turn on/off max anisotropy. - `BGFX_RESET_CAPTURE` - Begin screen capture. - `BGFX_RESET_FLUSH_AFTER_RENDER` - Flush rendering after submitting to GPU. - `BGFX_RESET_FLIP_AFTER_RENDER` - This flag specifies where flip occurs. Default behaviour is that flip occurs before rendering new frame. This flag only has effect when `BGFX_CONFIG_MULTITHREADED=0`. - `BGFX_RESET_SRGB_BACKBUFFER` - Enable sRGB back-buffer.</param>
/// <param name="_format">Texture format. See: `TextureFormat::Enum`.</param>
///
[LinkName("bgfx_reset")]
@@ -2757,7 +2757,7 @@ public static class bgfx
public static extern DynamicIndexBufferHandle create_dynamic_index_buffer(uint32 _num, uint16 _flags);
/// <summary>
/// Create dynamic index buffer and initialized it.
/// Create a dynamic index buffer and initialize it.
/// </summary>
///
/// <param name="_mem">Index buffer data.</param>
@@ -3066,7 +3066,7 @@ public static class bgfx
public static extern TextureHandle create_texture_2d(uint16 _width, uint16 _height, bool _hasMips, uint16 _numLayers, TextureFormat _format, uint64 _flags, Memory* _mem);
/// <summary>
/// Create texture with size based on backbuffer ratio. Texture will maintain ratio
/// Create texture with size based on back-buffer ratio. Texture will maintain ratio
/// if back buffer resolution changes.
/// </summary>
///
@@ -3220,7 +3220,7 @@ public static class bgfx
public static extern FrameBufferHandle create_frame_buffer(uint16 _width, uint16 _height, TextureFormat _format, uint64 _textureFlags);
/// <summary>
/// Create frame buffer with size based on backbuffer ratio. Frame buffer will maintain ratio
/// Create frame buffer with size based on back-buffer ratio. Frame buffer will maintain ratio
/// if back buffer resolution changes.
/// </summary>
///
@@ -3468,8 +3468,8 @@ public static class bgfx
/// <summary>
/// Set view clear flags with different clear color for each
/// frame buffer texture. Must use `bgfx::setPaletteColor` to setup clear color
/// palette.
/// frame buffer texture. `bgfx::setPaletteColor` must be used to set up a
/// clear color palette.
/// </summary>
///
/// <param name="_id">View id.</param>
@@ -3513,8 +3513,8 @@ public static class bgfx
public static extern void set_view_frame_buffer(ViewId _id, FrameBufferHandle _handle);
/// <summary>
/// Set view view and projection matrices, all draw primitives in this
/// view will use these matrices.
/// Set view's view matrix and projection matrix,
/// all draw primitives in this view will use these two matrices.
/// </summary>
///
/// <param name="_id">View id.</param>
@@ -3573,7 +3573,7 @@ public static class bgfx
/// <summary>
/// Set render states for draw primitive.
/// @remarks
/// 1. To setup more complex states use:
/// 1. To set up more complex states use:
/// `BGFX_STATE_ALPHA_REF(_ref)`,
/// `BGFX_STATE_POINT_SIZE(_size)`,
/// `BGFX_STATE_BLEND_FUNC(_src, _dst)`,
@@ -4121,7 +4121,7 @@ public static class bgfx
/// <summary>
/// Set render states for draw primitive.
/// @remarks
/// 1. To setup more complex states use:
/// 1. To set up more complex states use:
/// `BGFX_STATE_ALPHA_REF(_ref)`,
/// `BGFX_STATE_POINT_SIZE(_size)`,
/// `BGFX_STATE_BLEND_FUNC(_src, _dst)`,

View File

@@ -2443,7 +2443,7 @@ public static partial class bgfx
public static extern unsafe void init_ctor(Init* _init);
/// <summary>
/// Initialize bgfx library.
/// Initialize the bgfx library.
/// </summary>
///
/// <param name="_init">Initialization parameters. See: `bgfx::Init` for more info.</param>
@@ -2461,13 +2461,13 @@ public static partial class bgfx
/// <summary>
/// Reset graphic settings and back-buffer size.
/// @attention This call doesn't actually change window size, it just
/// resizes back-buffer. Windowing code has to change window size.
/// @attention This call doesnt change the window size, it just resizes
/// the back-buffer. Your windowing code controls the window size.
/// </summary>
///
/// <param name="_width">Back-buffer width.</param>
/// <param name="_height">Back-buffer height.</param>
/// <param name="_flags">See: `BGFX_RESET_*` for more info. - `BGFX_RESET_NONE` - No reset flags. - `BGFX_RESET_FULLSCREEN` - Not supported yet. - `BGFX_RESET_MSAA_X[2/4/8/16]` - Enable 2, 4, 8 or 16 x MSAA. - `BGFX_RESET_VSYNC` - Enable V-Sync. - `BGFX_RESET_MAXANISOTROPY` - Turn on/off max anisotropy. - `BGFX_RESET_CAPTURE` - Begin screen capture. - `BGFX_RESET_FLUSH_AFTER_RENDER` - Flush rendering after submitting to GPU. - `BGFX_RESET_FLIP_AFTER_RENDER` - This flag specifies where flip occurs. Default behaviour is that flip occurs before rendering new frame. This flag only has effect when `BGFX_CONFIG_MULTITHREADED=0`. - `BGFX_RESET_SRGB_BACKBUFFER` - Enable sRGB backbuffer.</param>
/// <param name="_flags">See: `BGFX_RESET_*` for more info. - `BGFX_RESET_NONE` - No reset flags. - `BGFX_RESET_FULLSCREEN` - Not supported yet. - `BGFX_RESET_MSAA_X[2/4/8/16]` - Enable 2, 4, 8 or 16 x MSAA. - `BGFX_RESET_VSYNC` - Enable V-Sync. - `BGFX_RESET_MAXANISOTROPY` - Turn on/off max anisotropy. - `BGFX_RESET_CAPTURE` - Begin screen capture. - `BGFX_RESET_FLUSH_AFTER_RENDER` - Flush rendering after submitting to GPU. - `BGFX_RESET_FLIP_AFTER_RENDER` - This flag specifies where flip occurs. Default behaviour is that flip occurs before rendering new frame. This flag only has effect when `BGFX_CONFIG_MULTITHREADED=0`. - `BGFX_RESET_SRGB_BACKBUFFER` - Enable sRGB back-buffer.</param>
/// <param name="_format">Texture format. See: `TextureFormat::Enum`.</param>
///
[DllImport(DllName, EntryPoint="bgfx_reset", CallingConvention = CallingConvention.Cdecl)]
@@ -2711,7 +2711,7 @@ public static partial class bgfx
public static extern unsafe DynamicIndexBufferHandle create_dynamic_index_buffer(uint _num, ushort _flags);
/// <summary>
/// Create dynamic index buffer and initialized it.
/// Create a dynamic index buffer and initialize it.
/// </summary>
///
/// <param name="_mem">Index buffer data.</param>
@@ -3023,7 +3023,7 @@ public static partial class bgfx
public static extern unsafe TextureHandle create_texture_2d(ushort _width, ushort _height, bool _hasMips, ushort _numLayers, TextureFormat _format, ulong _flags, Memory* _mem);
/// <summary>
/// Create texture with size based on backbuffer ratio. Texture will maintain ratio
/// Create texture with size based on back-buffer ratio. Texture will maintain ratio
/// if back buffer resolution changes.
/// </summary>
///
@@ -3177,7 +3177,7 @@ public static partial class bgfx
public static extern unsafe FrameBufferHandle create_frame_buffer(ushort _width, ushort _height, TextureFormat _format, ulong _textureFlags);
/// <summary>
/// Create frame buffer with size based on backbuffer ratio. Frame buffer will maintain ratio
/// Create frame buffer with size based on back-buffer ratio. Frame buffer will maintain ratio
/// if back buffer resolution changes.
/// </summary>
///
@@ -3425,8 +3425,8 @@ public static partial class bgfx
/// <summary>
/// Set view clear flags with different clear color for each
/// frame buffer texture. Must use `bgfx::setPaletteColor` to setup clear color
/// palette.
/// frame buffer texture. `bgfx::setPaletteColor` must be used to set up a
/// clear color palette.
/// </summary>
///
/// <param name="_id">View id.</param>
@@ -3470,8 +3470,8 @@ public static partial class bgfx
public static extern unsafe void set_view_frame_buffer(ushort _id, FrameBufferHandle _handle);
/// <summary>
/// Set view view and projection matrices, all draw primitives in this
/// view will use these matrices.
/// Set view's view matrix and projection matrix,
/// all draw primitives in this view will use these two matrices.
/// </summary>
///
/// <param name="_id">View id.</param>
@@ -3530,7 +3530,7 @@ public static partial class bgfx
/// <summary>
/// Set render states for draw primitive.
/// @remarks
/// 1. To setup more complex states use:
/// 1. To set up more complex states use:
/// `BGFX_STATE_ALPHA_REF(_ref)`,
/// `BGFX_STATE_POINT_SIZE(_size)`,
/// `BGFX_STATE_BLEND_FUNC(_src, _dst)`,
@@ -4078,7 +4078,7 @@ public static partial class bgfx
/// <summary>
/// Set render states for draw primitive.
/// @remarks
/// 1. To setup more complex states use:
/// 1. To set up more complex states use:
/// `BGFX_STATE_ALPHA_REF(_ref)`,
/// `BGFX_STATE_POINT_SIZE(_size)`,
/// `BGFX_STATE_BLEND_FUNC(_src, _dst)`,

View File

@@ -178,7 +178,7 @@ version(BindBgfx_Static)
void bgfx_init_ctor(bgfx_init_t* _init);
/**
* Initialize bgfx library.
* Initialize the bgfx library.
* Params:
* _init = Initialization parameters. See: `bgfx::Init` for more info.
*/
@@ -191,8 +191,8 @@ version(BindBgfx_Static)
/**
* Reset graphic settings and back-buffer size.
* Attention: This call doesn't actually change window size, it just
* resizes back-buffer. Windowing code has to change window size.
* Attention: This call doesnt change the window size, it just resizes
* the back-buffer. Your windowing code controls the window size.
* Params:
* _width = Back-buffer width.
* _height = Back-buffer height.
@@ -207,7 +207,7 @@ version(BindBgfx_Static)
* - `BGFX_RESET_FLIP_AFTER_RENDER` - This flag specifies where flip
* occurs. Default behaviour is that flip occurs before rendering new
* frame. This flag only has effect when `BGFX_CONFIG_MULTITHREADED=0`.
* - `BGFX_RESET_SRGB_BACKBUFFER` - Enable sRGB backbuffer.
* - `BGFX_RESET_SRGB_BACKBUFFER` - Enable sRGB back-buffer.
* _format = Texture format. See: `TextureFormat::Enum`.
*/
void bgfx_reset(uint _width, uint _height, uint _flags, bgfx_texture_format_t _format);
@@ -449,7 +449,7 @@ version(BindBgfx_Static)
bgfx_dynamic_index_buffer_handle_t bgfx_create_dynamic_index_buffer(uint _num, ushort _flags);
/**
* Create dynamic index buffer and initialized it.
* Create a dynamic index buffer and initialize it.
* Params:
* _mem = Index buffer data.
* _flags = Buffer creation flags.
@@ -759,7 +759,7 @@ version(BindBgfx_Static)
bgfx_texture_handle_t bgfx_create_texture_2d(ushort _width, ushort _height, bool _hasMips, ushort _numLayers, bgfx_texture_format_t _format, ulong _flags, const(bgfx_memory_t)* _mem);
/**
* Create texture with size based on backbuffer ratio. Texture will maintain ratio
* Create texture with size based on back-buffer ratio. Texture will maintain ratio
* if back buffer resolution changes.
* Params:
* _ratio = Texture size in respect to back-buffer size. See: `BackbufferRatio::Enum`.
@@ -937,7 +937,7 @@ version(BindBgfx_Static)
bgfx_frame_buffer_handle_t bgfx_create_frame_buffer(ushort _width, ushort _height, bgfx_texture_format_t _format, ulong _textureFlags);
/**
* Create frame buffer with size based on backbuffer ratio. Frame buffer will maintain ratio
* Create frame buffer with size based on back-buffer ratio. Frame buffer will maintain ratio
* if back buffer resolution changes.
* Params:
* _ratio = Frame buffer size in respect to back-buffer size. See:
@@ -1157,8 +1157,8 @@ version(BindBgfx_Static)
/**
* Set view clear flags with different clear color for each
* frame buffer texture. Must use `bgfx::setPaletteColor` to setup clear color
* palette.
* frame buffer texture. `bgfx::setPaletteColor` must be used to set up a
* clear color palette.
* Params:
* _id = View id.
* _flags = Clear flags. Use `BGFX_CLEAR_NONE` to remove any clear
@@ -1199,8 +1199,8 @@ version(BindBgfx_Static)
void bgfx_set_view_frame_buffer(bgfx_view_id_t _id, bgfx_frame_buffer_handle_t _handle);
/**
* Set view view and projection matrices, all draw primitives in this
* view will use these matrices.
* Set view's view matrix and projection matrix,
* all draw primitives in this view will use these two matrices.
* Params:
* _id = View id.
* _view = View matrix.
@@ -1248,7 +1248,7 @@ version(BindBgfx_Static)
/**
* Set render states for draw primitive.
* Remarks:
* 1. To setup more complex states use:
* 1. To set up more complex states use:
* `BGFX_STATE_ALPHA_REF(_ref)`,
* `BGFX_STATE_POINT_SIZE(_size)`,
* `BGFX_STATE_BLEND_FUNC(_src, _dst)`,
@@ -1739,7 +1739,7 @@ version(BindBgfx_Static)
/**
* Set render states for draw primitive.
* Remarks:
* 1. To setup more complex states use:
* 1. To set up more complex states use:
* `BGFX_STATE_ALPHA_REF(_ref)`,
* `BGFX_STATE_POINT_SIZE(_size)`,
* `BGFX_STATE_BLEND_FUNC(_src, _dst)`,
@@ -2338,7 +2338,7 @@ else
da_bgfx_init_ctor bgfx_init_ctor;
/**
* Initialize bgfx library.
* Initialize the bgfx library.
* Params:
* _init = Initialization parameters. See: `bgfx::Init` for more info.
*/
@@ -2353,8 +2353,8 @@ else
/**
* Reset graphic settings and back-buffer size.
* Attention: This call doesn't actually change window size, it just
* resizes back-buffer. Windowing code has to change window size.
* Attention: This call doesnt change the window size, it just resizes
* the back-buffer. Your windowing code controls the window size.
* Params:
* _width = Back-buffer width.
* _height = Back-buffer height.
@@ -2369,7 +2369,7 @@ else
* - `BGFX_RESET_FLIP_AFTER_RENDER` - This flag specifies where flip
* occurs. Default behaviour is that flip occurs before rendering new
* frame. This flag only has effect when `BGFX_CONFIG_MULTITHREADED=0`.
* - `BGFX_RESET_SRGB_BACKBUFFER` - Enable sRGB backbuffer.
* - `BGFX_RESET_SRGB_BACKBUFFER` - Enable sRGB back-buffer.
* _format = Texture format. See: `TextureFormat::Enum`.
*/
alias da_bgfx_reset = void function(uint _width, uint _height, uint _flags, bgfx_texture_format_t _format);
@@ -2634,7 +2634,7 @@ else
da_bgfx_create_dynamic_index_buffer bgfx_create_dynamic_index_buffer;
/**
* Create dynamic index buffer and initialized it.
* Create a dynamic index buffer and initialize it.
* Params:
* _mem = Index buffer data.
* _flags = Buffer creation flags.
@@ -2972,7 +2972,7 @@ else
da_bgfx_create_texture_2d bgfx_create_texture_2d;
/**
* Create texture with size based on backbuffer ratio. Texture will maintain ratio
* Create texture with size based on back-buffer ratio. Texture will maintain ratio
* if back buffer resolution changes.
* Params:
* _ratio = Texture size in respect to back-buffer size. See: `BackbufferRatio::Enum`.
@@ -3161,7 +3161,7 @@ else
da_bgfx_create_frame_buffer bgfx_create_frame_buffer;
/**
* Create frame buffer with size based on backbuffer ratio. Frame buffer will maintain ratio
* Create frame buffer with size based on back-buffer ratio. Frame buffer will maintain ratio
* if back buffer resolution changes.
* Params:
* _ratio = Frame buffer size in respect to back-buffer size. See:
@@ -3401,8 +3401,8 @@ else
/**
* Set view clear flags with different clear color for each
* frame buffer texture. Must use `bgfx::setPaletteColor` to setup clear color
* palette.
* frame buffer texture. `bgfx::setPaletteColor` must be used to set up a
* clear color palette.
* Params:
* _id = View id.
* _flags = Clear flags. Use `BGFX_CLEAR_NONE` to remove any clear
@@ -3446,8 +3446,8 @@ else
da_bgfx_set_view_frame_buffer bgfx_set_view_frame_buffer;
/**
* Set view view and projection matrices, all draw primitives in this
* view will use these matrices.
* Set view's view matrix and projection matrix,
* all draw primitives in this view will use these two matrices.
* Params:
* _id = View id.
* _view = View matrix.
@@ -3501,7 +3501,7 @@ else
/**
* Set render states for draw primitive.
* Remarks:
* 1. To setup more complex states use:
* 1. To set up more complex states use:
* `BGFX_STATE_ALPHA_REF(_ref)`,
* `BGFX_STATE_POINT_SIZE(_size)`,
* `BGFX_STATE_BLEND_FUNC(_src, _dst)`,
@@ -4037,7 +4037,7 @@ else
/**
* Set render states for draw primitive.
* Remarks:
* 1. To setup more complex states use:
* 1. To set up more complex states use:
* `BGFX_STATE_ALPHA_REF(_ref)`,
* `BGFX_STATE_POINT_SIZE(_size)`,
* `BGFX_STATE_BLEND_FUNC(_src, _dst)`,

View File

@@ -838,11 +838,16 @@ struct bgfx_platform_data_t
void* ndt; /// Native display type (*nix specific).
/**
* Native window handle. If `NULL` bgfx will create headless
* context/device if renderer API supports it.
* Native window handle. If `NULL`, bgfx will create a headless
* context/device, provided the rendering API supports it.
*/
void* nwh;
void* context; /// GL context, or D3D device. If `NULL`, bgfx will create context/device.
/**
* GL context, D3D device, or Vulkan device. If `NULL`, bgfx
* will create context/device.
*/
void* context;
/**
* GL back-buffer, or D3D render target view. If `NULL` bgfx will
@@ -851,7 +856,7 @@ struct bgfx_platform_data_t
void* backBuffer;
/**
* Backbuffer depth/stencil. If `NULL` bgfx will create back-buffer
* Backbuffer depth/stencil. If `NULL`, bgfx will create a back-buffer
* depth/stencil surface.
*/
void* backBufferDS;

File diff suppressed because it is too large Load Diff

View File

@@ -591,11 +591,16 @@ typedef struct bgfx_platform_data_s
void* ndt; /** Native display type (*nix specific). */
/**
* Native window handle. If `NULL` bgfx will create headless
* context/device if renderer API supports it.
* Native window handle. If `NULL`, bgfx will create a headless
* context/device, provided the rendering API supports it.
*/
void* nwh;
void* context; /** GL context, or D3D device. If `NULL`, bgfx will create context/device. */
/**
* GL context, D3D device, or Vulkan device. If `NULL`, bgfx
* will create context/device.
*/
void* context;
/**
* GL back-buffer, or D3D render target view. If `NULL` bgfx will
@@ -604,7 +609,7 @@ typedef struct bgfx_platform_data_s
void* backBuffer;
/**
* Backbuffer depth/stencil. If `NULL` bgfx will create back-buffer
* Backbuffer depth/stencil. If `NULL`, bgfx will create a back-buffer
* depth/stencil surface.
*/
void* backBufferDS;
@@ -1098,7 +1103,7 @@ BGFX_C_API const char* bgfx_get_renderer_name(bgfx_renderer_type_t _type);
BGFX_C_API void bgfx_init_ctor(bgfx_init_t* _init);
/**
* Initialize bgfx library.
* Initialize the bgfx library.
*
* @param[in] _init Initialization parameters. See: `bgfx::Init` for more info.
*
@@ -1115,8 +1120,8 @@ BGFX_C_API void bgfx_shutdown(void);
/**
* Reset graphic settings and back-buffer size.
* @attention This call doesn't actually change window size, it just
* resizes back-buffer. Windowing code has to change window size.
* @attention This call doesnt change the window size, it just resizes
* the back-buffer. Your windowing code controls the window size.
*
* @param[in] _width Back-buffer width.
* @param[in] _height Back-buffer height.
@@ -1131,7 +1136,7 @@ BGFX_C_API void bgfx_shutdown(void);
* - `BGFX_RESET_FLIP_AFTER_RENDER` - This flag specifies where flip
* occurs. Default behaviour is that flip occurs before rendering new
* frame. This flag only has effect when `BGFX_CONFIG_MULTITHREADED=0`.
* - `BGFX_RESET_SRGB_BACKBUFFER` - Enable sRGB backbuffer.
* - `BGFX_RESET_SRGB_BACKBUFFER` - Enable sRGB back-buffer.
* @param[in] _format Texture format. See: `TextureFormat::Enum`.
*
*/
@@ -1413,7 +1418,7 @@ BGFX_C_API void bgfx_destroy_vertex_buffer(bgfx_vertex_buffer_handle_t _handle);
BGFX_C_API bgfx_dynamic_index_buffer_handle_t bgfx_create_dynamic_index_buffer(uint32_t _num, uint16_t _flags);
/**
* Create dynamic index buffer and initialized it.
* Create a dynamic index buffer and initialize it.
*
* @param[in] _mem Index buffer data.
* @param[in] _flags Buffer creation flags.
@@ -1708,7 +1713,7 @@ BGFX_C_API void bgfx_destroy_program(bgfx_program_handle_t _handle);
* @param[in] _format Texture format. See: `TextureFormat::Enum`.
* @param[in] _flags Texture flags. See `BGFX_TEXTURE_*`.
*
* @returns True if texture can be successfully created.
* @returns True if a texture with the same parameters can be created.
*
*/
BGFX_C_API bool bgfx_is_texture_valid(uint16_t _depth, bool _cubeMap, uint16_t _numLayers, bgfx_texture_format_t _format, uint64_t _flags);
@@ -1719,7 +1724,7 @@ BGFX_C_API bool bgfx_is_texture_valid(uint16_t _depth, bool _cubeMap, uint16_t _
* @param[in] _num Number of attachments.
* @param[in] _attachment Attachment texture info. See: `bgfx::Attachment`.
*
* @returns True if frame buffer can be successfully created.
* @returns True if a frame buffer with the same parameters can be created.
*
*/
BGFX_C_API bool bgfx_is_frame_buffer_valid(uint8_t _num, const bgfx_attachment_t* _attachment);
@@ -1782,7 +1787,7 @@ BGFX_C_API bgfx_texture_handle_t bgfx_create_texture(const bgfx_memory_t* _mem,
BGFX_C_API bgfx_texture_handle_t bgfx_create_texture_2d(uint16_t _width, uint16_t _height, bool _hasMips, uint16_t _numLayers, bgfx_texture_format_t _format, uint64_t _flags, const bgfx_memory_t* _mem);
/**
* Create texture with size based on backbuffer ratio. Texture will maintain ratio
* Create texture with size based on back-buffer ratio. Texture will maintain ratio
* if back buffer resolution changes.
*
* @param[in] _ratio Texture size in respect to back-buffer size. See: `BackbufferRatio::Enum`.
@@ -1986,7 +1991,7 @@ BGFX_C_API void bgfx_destroy_texture(bgfx_texture_handle_t _handle);
BGFX_C_API bgfx_frame_buffer_handle_t bgfx_create_frame_buffer(uint16_t _width, uint16_t _height, bgfx_texture_format_t _format, uint64_t _textureFlags);
/**
* Create frame buffer with size based on backbuffer ratio. Frame buffer will maintain ratio
* Create frame buffer with size based on back-buffer ratio. Frame buffer will maintain ratio
* if back buffer resolution changes.
*
* @param[in] _ratio Frame buffer size in respect to back-buffer size. See:
@@ -2239,8 +2244,8 @@ BGFX_C_API void bgfx_set_view_clear(bgfx_view_id_t _id, uint16_t _flags, uint32_
/**
* Set view clear flags with different clear color for each
* frame buffer texture. Must use `bgfx::setPaletteColor` to setup clear color
* palette.
* frame buffer texture. `bgfx::setPaletteColor` must be used to set up a
* clear color palette.
*
* @param[in] _id View id.
* @param[in] _flags Clear flags. Use `BGFX_CLEAR_NONE` to remove any clear
@@ -2284,8 +2289,8 @@ BGFX_C_API void bgfx_set_view_mode(bgfx_view_id_t _id, bgfx_view_mode_t _mode);
BGFX_C_API void bgfx_set_view_frame_buffer(bgfx_view_id_t _id, bgfx_frame_buffer_handle_t _handle);
/**
* Set view view and projection matrices, all draw primitives in this
* view will use these matrices.
* Set view's view matrix and projection matrix,
* all draw primitives in this view will use these two matrices.
*
* @param[in] _id View id.
* @param[in] _view View matrix.
@@ -2343,7 +2348,7 @@ BGFX_C_API void bgfx_encoder_set_marker(bgfx_encoder_t* _this, const char* _mark
/**
* Set render states for draw primitive.
* @remarks
* 1. To setup more complex states use:
* 1. To set up more complex states use:
* `BGFX_STATE_ALPHA_REF(_ref)`,
* `BGFX_STATE_POINT_SIZE(_size)`,
* `BGFX_STATE_BLEND_FUNC(_src, _dst)`,
@@ -2894,7 +2899,7 @@ BGFX_C_API void bgfx_set_marker(const char* _marker);
/**
* Set render states for draw primitive.
* @remarks
* 1. To setup more complex states use:
* 1. To set up more complex states use:
* `BGFX_STATE_ALPHA_REF(_ref)`,
* `BGFX_STATE_POINT_SIZE(_size)`,
* `BGFX_STATE_BLEND_FUNC(_src, _dst)`,

View File

@@ -17,7 +17,7 @@ namespace bgfx
{
/// Render frame enum.
///
/// @attention C99 equivalent is `bgfx_render_frame_t`.
/// @attention C99's equivalent binding is `bgfx_render_frame_t`.
///
struct RenderFrame
{
@@ -47,7 +47,7 @@ namespace bgfx
/// allow creating separate rendering thread. If it is called before
/// to bgfx::init, render thread won't be created by bgfx::init call.
///
/// @attention C99 equivalent is `bgfx_render_frame`.
/// @attention C99's equivalent binding is `bgfx_render_frame`.
///
RenderFrame::Enum renderFrame(int32_t _msecs = -1);
@@ -55,13 +55,13 @@ namespace bgfx
///
/// @warning Must be called before `bgfx::init`.
///
/// @attention C99 equivalent is `bgfx_set_platform_data`.
/// @attention C99's equivalent binding is `bgfx_set_platform_data`.
///
void setPlatformData(const PlatformData& _data);
/// Internal data.
///
/// @attention C99 equivalent is `bgfx_internal_data_t`.
/// @attention C99's equivalent binding is `bgfx_internal_data_t`.
///
struct InternalData
{
@@ -76,7 +76,7 @@ namespace bgfx
///
/// @warning Must be called only on render thread.
///
/// @attention C99 equivalent is `bgfx_get_internal_data`.
/// @attention C99's equivalent binding is `bgfx_get_internal_data`.
///
const InternalData* getInternalData();
@@ -94,7 +94,7 @@ namespace bgfx
///
/// @warning Must be called only on render thread.
///
/// @attention C99 equivalent is `bgfx_override_internal_texture_ptr`.
/// @attention C99's equivalent binding is `bgfx_override_internal_texture_ptr`.
///
uintptr_t overrideInternal(TextureHandle _handle, uintptr_t _ptr);
@@ -121,7 +121,7 @@ namespace bgfx
///
/// @warning Must be called only on render thread.
///
/// @attention C99 equivalent is `bgfx_override_internal_texture`.
/// @attention C99's equivalent binding is `bgfx_override_internal_texture`.
///
uintptr_t overrideInternal(
TextureHandle _handle