Commit Graph

79 Commits

Author SHA1 Message Date
Бранимир Караџић
82f56b5987 Happy New Year! 2020-01-14 21:37:06 -08:00
Oliver Collyer
aeb77dde38 Overloaded nvgluCreateFramebuffer functions
Added overloaded nvgluCreateFramebuffer functions for creating a framebuffer that automatically mirrors the size of the back buffer
2020-01-05 08:43:53 -08:00
Leandro Freire
1db46f4fe6 Rename variables and constants 2019-08-17 12:32:16 -07:00
Leandro Freire
855623e153 Rename VertexDecl to VertexLayout 2019-08-13 18:42:01 -07:00
Martijn Courteaux
6c6f43cff0 Fixed gather after cleanup in 49bd00e. 2019-08-04 16:58:25 -07:00
Бранимир Караџић
3f3a9450ba Happy New Year! 2019-01-13 17:13:25 -08:00
Бранимир Караџић
a54f8a3f81 Renamed UniformType enum Int1 to Sampler. 2019-01-11 14:14:17 -08:00
Mathieu-Andre Chiasson
5be52bb925 upgraded nanovg to the latest. 2018-12-27 21:52:01 -05:00
Branimir Karadžić
4433b5bcdc Separating sampler flags from texture creation flags. 2018-08-20 17:12:26 -07:00
Branimir Karadžić
15485134f7 Updated nanovg. 2018-03-01 09:05:54 -08:00
Branimir Karadžić
584b8b34f0 Added support for independent RGB channel write control. 2018-02-13 12:35:23 -08:00
Branimir Karadžić
f44c8e2b14 Happy New Year! 2018-01-01 11:16:06 -08:00
Branimir Karadžić
f88c44a835 Cleanup. 2017-11-28 08:44:47 -08:00
Branimir Karadžić
e7bcae2dfd Cleanup. 2017-11-27 19:44:27 -08:00
Branimir Karadžić
7c9b2b7257 API change: Simplified destroy functions to use overload resolution. 2017-07-17 22:29:43 -07:00
Branimir Karadžić
3e212b519f Moving code around and renaming files. 2017-07-15 21:01:08 -07:00
Branimir Karadžić
6910ddba9e WIP: Adding more sort key modes. 2017-06-14 18:10:42 -07:00
Branimir Karadžić
6a6c5e3af9 Cleanup. 2017-06-10 22:31:59 -07:00
Branimir Karadžić
07d799f72e Renamed constants to new style. 2017-06-09 21:57:08 -07:00
Olli Wang
ed99f83093 Fixes texture format for NanoVG framebuffer. (#1147)
* Fixes pixel format for iOS.

* Fixes texture format of nanovg framebuffer.
2017-06-04 09:53:19 -07:00
Branimir Karadžić
c0f37bc121 Fixed #1136 premultiplied alpha. 2017-05-24 21:15:08 -07:00
Branimir Karadžić
54411a2b5d Fixed issue #1136 cont. 2017-05-24 08:55:45 -07:00
Branimir Karadžić
1e3f8e2965 Fixed issue #1136. 2017-05-20 17:15:19 -07:00
Branimir Karadžić
68c6b46a65 Exposed vertex stream argument to API. 2017-05-14 11:48:59 -07:00
Branimir Karadžić
9128c4f374 Fixed NanoVG. 2017-04-12 20:53:58 -07:00
Branimir Karadžić
0aa79d3ac4 Cleanup. 2017-03-25 21:04:58 -07:00
Olli Wang
b761d1240c Allows to set view id of NanoVG’s framebuffer manually.
This commit changes the `nvgluCreateFramebuffer()` function to not assign a view id automatically as it would easily reach the limit of `uint8_t`. Instead, a new `nvgluSetViewFramebuffer()` function is created to allow users to assign the view id manually as mentioned in #1095.
2017-03-26 11:03:52 +08:00
jdryg
b23af90947 nvgRenderUpdateTexture() was reading past the end of the data buffer. 2017-03-24 11:59:16 +02:00
Olli Wang
4bdaf42ccf Updates NanoVG to the latest commit.
This commit updates NanoVG's bgfx backend to match the original NanoVG's latest commit, which has significant changes about composite operation implementation as mentioned in pull request https://github.com/memononen/nanovg/pull/312.
2017-03-23 00:23:20 +08:00
Branimir Karadžić
64922762df Cleanup. 2017-02-06 16:22:08 -08:00
Branimir Karadžić
3b83f53ab1 Happy New Year! 2017-01-01 00:18:41 -08:00
Branimir Karadžić
58e46330cd Updated embedded shaders. 2016-12-05 16:55:49 -08:00
Branimir Karadžić
4afd337d5e Cleanup. 2016-12-04 19:52:48 -08:00
Branimir Karadžić
f9486780c2 Updated NaCl toolchain to v49. 2016-09-02 21:25:01 -07:00
Branimir Karadžić
7537b705e5 GL: Added support for texture array. 2016-08-21 14:03:16 -07:00
Branimir Karadžić
c98be90bf5 WIP: Texture array support. 2016-08-19 21:05:37 -07:00
Branimir Karadžić
2c861766e8 Switch iffy translation code to lookup table translation. 2016-08-10 20:36:21 -07:00
Olli Wang
1804ba77c1 Updates nanovg to support global composite operation. (#877)
This commit updates bgfx's NanoVG codebase to adapt the latest NanoVG commit since I've implemented blending support for the original NanoVG and there is no need of `nvgState()` anymore.
2016-08-10 20:15:31 -07:00
Olli Wang
b9810aca70 Updates nanovg backend to adopt premultiplied alpha. (#873)
This commit updates nanovg's bgfx backend to adopt premultiplied alpha as the default blending mode just like the original nanovg. Both the fragment shader and the `glnvg__convertPaint()` function are updated to match the original nanovg counterpart.

However, the binary file of the fragment shader is built on Mac so DirectX support is missing.
2016-08-09 22:44:04 -07:00
Branimir Karadžić
c25a273e29 Cleanup. 2016-08-08 09:23:42 -07:00
Olli Wang
f11d954bc1 Implements nanovg's framebuffer helper functions. (#869)
This commit ports nanovg's helper functions for rendering stuff in framebuffer defined in `nanovg_gl_utils.h`. Also, a new `nvgState()` function is created for bgfx backend so it is possible to blend between framebuffers, which feature is long requested but not yet supported in original nanovg. The `nvgState()` function can be called between `nvgBeginFrame()` and `nvgEndFrame()`.
2016-08-08 08:33:37 -07:00
Olli Wang
fa73aa4b09 Adds iOS device's Retina screen support for nanovg. (#865)
This commit fixes the bug that the bgfx does not respect the `devicePixelRatio` parameter passed to nanovg's `nvgBeginFrame()` function. The problem is caused by the `bgfx::setViewRect()` call defined in the `nvgRenderViewport()` function, as it should take size in consideration of the `devicePixelRatio` value.

However, this commit does not fix nanovg's example app because currently there is no easy way to pass the scale value to the `ExampleNanoVG::update()` method as it calls `nvgBeginFrame()`.
2016-08-05 09:50:02 -07:00
Olli Wang
c960c46564 Moves additional bgfx nanovg functions to a separate header file.
This commit moves the additional nanovg functions for bgfx to a separate header file, so it is possible to compile the original nanovg  source files with bgfx in a custom build environment.
2016-08-05 17:26:06 +08:00
Branimir Karadžić
dc46b1a36b Cleanup. 2016-02-21 13:59:38 -08:00
Branimir Karadžić
608e038b96 Manually merged PR #676. 2016-02-08 12:53:19 -08:00
Branimir Karadžić
728a8ee4e5 NanoVG: Added ability to pass custom allocator. 2016-02-07 18:58:17 -08:00
Branimir Karadžić
6af72ce686 nanovg: Allow texture update after creation. 2016-01-25 09:26:14 -08:00
Branimir Karadžić
ab9a0c12b0 Cleanup. 2016-01-12 13:20:07 -08:00
Branimir Karadžić
4bb2b623d3 Happy New Year! 2016-01-01 00:11:04 -08:00
Branimir Karadžić
46822b242a Updated NanoVG. 2015-12-05 11:00:11 -08:00