From 000a3b704c145a1437b099148a1eb45d17a9c5ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=91=D1=80=D0=B0=D0=BD=D0=B8=D0=BC=D0=B8=D1=80=20=D0=9A?= =?UTF-8?q?=D0=B0=D1=80=D0=B0=D1=9F=D0=B8=D1=9B?= Date: Tue, 14 Apr 2020 08:35:41 -0700 Subject: [PATCH] Cleanup. --- bindings/d/types.d | 25 ++++++++++++++++++++----- include/bgfx/bgfx.h | 13 ++++++++----- include/bgfx/c99/bgfx.h | 25 ++++++++++++++++++++----- scripts/bgfx.idl | 13 ++++++++----- src/version.h | 4 ++-- 5 files changed, 58 insertions(+), 22 deletions(-) diff --git a/bindings/d/types.d b/bindings/d/types.d index b7219e32e..4f42a3958 100644 --- a/bindings/d/types.d +++ b/bindings/d/types.d @@ -780,11 +780,26 @@ struct bgfx_internal_data_t /// Platform data. struct bgfx_platform_data_t { - void* ndt; /// Native display type. - void* nwh; /// Native window handle. - void* context; /// GL context, or D3D device. - void* backBuffer; /// GL backbuffer, or D3D render target view. - void* backBufferDS; /// Backbuffer depth/stencil. + void* ndt; /// Native display type (*nix specific). + + /** + * Native window handle. If `NULL` bgfx will create headless + * context/device if renderer API supports it. + */ + void* nwh; + void* context; /// GL context, or D3D device. If `NULL`, bgfx will create context/device. + + /** + * GL back-buffer, or D3D render target view. If `NULL` bgfx will + * create back-buffer color surface. + */ + void* backBuffer; + + /** + * Backbuffer depth/stencil. If `NULL` bgfx will create back-buffer + * depth/stencil surface. + */ + void* backBufferDS; } /// Backbuffer resolution and reset parameters. diff --git a/include/bgfx/bgfx.h b/include/bgfx/bgfx.h index cba9fd55d..38fc59176 100644 --- a/include/bgfx/bgfx.h +++ b/include/bgfx/bgfx.h @@ -609,11 +609,14 @@ namespace bgfx { PlatformData(); - void* ndt; //!< Native display type. - void* nwh; //!< Native window handle. - void* context; //!< GL context, or D3D device. - void* backBuffer; //!< GL backbuffer, or D3D render target view. - void* backBufferDS; //!< Backbuffer depth/stencil. + void* ndt; //!< Native display type (*nix specific). + void* nwh; //!< Native window handle. If `NULL` bgfx will create headless + /// context/device if renderer API supports it. + void* context; //!< GL context, or D3D device. If `NULL`, bgfx will create context/device. + void* backBuffer; //!< GL back-buffer, or D3D render target view. If `NULL` bgfx will + /// create back-buffer color surface. + void* backBufferDS; //!< Backbuffer depth/stencil. If `NULL` bgfx will create back-buffer + /// depth/stencil surface. }; /// Backbuffer resolution and reset parameters. diff --git a/include/bgfx/c99/bgfx.h b/include/bgfx/c99/bgfx.h index a004cd8fc..3b78c38d3 100644 --- a/include/bgfx/c99/bgfx.h +++ b/include/bgfx/c99/bgfx.h @@ -583,11 +583,26 @@ typedef struct bgfx_internal_data_s */ typedef struct bgfx_platform_data_s { - void* ndt; /** Native display type. */ - void* nwh; /** Native window handle. */ - void* context; /** GL context, or D3D device. */ - void* backBuffer; /** GL backbuffer, or D3D render target view. */ - void* backBufferDS; /** Backbuffer depth/stencil. */ + void* ndt; /** Native display type (*nix specific). */ + + /** + * Native window handle. If `NULL` bgfx will create headless + * context/device if renderer API supports it. + */ + void* nwh; + void* context; /** GL context, or D3D device. If `NULL`, bgfx will create context/device. */ + + /** + * GL back-buffer, or D3D render target view. If `NULL` bgfx will + * create back-buffer color surface. + */ + void* backBuffer; + + /** + * Backbuffer depth/stencil. If `NULL` bgfx will create back-buffer + * depth/stencil surface. + */ + void* backBufferDS; } bgfx_platform_data_t; diff --git a/scripts/bgfx.idl b/scripts/bgfx.idl index e06705d38..67ae019a5 100644 --- a/scripts/bgfx.idl +++ b/scripts/bgfx.idl @@ -744,11 +744,14 @@ struct.InternalData --- Platform data. struct.PlatformData { ctor } - .ndt "void*" --- Native display type. - .nwh "void*" --- Native window handle. - .context "void*" --- GL context, or D3D device. - .backBuffer "void*" --- GL backbuffer, or D3D render target view. - .backBufferDS "void*" --- Backbuffer depth/stencil. + .ndt "void*" --- Native display type (*nix specific). + .nwh "void*" --- Native window handle. If `NULL` bgfx will create headless + --- context/device if renderer API supports it. + .context "void*" --- GL context, or D3D device. If `NULL`, bgfx will create context/device. + .backBuffer "void*" --- GL back-buffer, or D3D render target view. If `NULL` bgfx will + --- create back-buffer color surface. + .backBufferDS "void*" --- Backbuffer depth/stencil. If `NULL` bgfx will create back-buffer + --- depth/stencil surface. --- Backbuffer resolution and reset parameters. struct.Resolution { ctor } diff --git a/src/version.h b/src/version.h index ceb619763..29acddff7 100644 --- a/src/version.h +++ b/src/version.h @@ -9,5 +9,5 @@ * */ -#define BGFX_REV_NUMBER 7085 -#define BGFX_REV_SHA1 "06460b8ac23e152f42d342dd58d491c3d1764f5b" +#define BGFX_REV_NUMBER 7124 +#define BGFX_REV_SHA1 "4420bf420eb933c59b54bb7e25bba3ecb4422925"