Richard Davey
893453f840
New uniforms handler, new cache and dirty checks
2020-09-21 15:57:38 +01:00
Richard Davey
4549fb4320
Updated type defs
2020-09-21 14:05:51 +01:00
Richard Davey
f2f3aea79a
Shorter errors
2020-09-21 14:05:38 +01:00
Richard Davey
9bb510be0c
Now caches uniform locations and added all of the new set1f
etc uniform methods
2020-09-21 14:05:30 +01:00
Richard Davey
56caeb126f
Renders whole buffer in a single draw with no vertex iteration
2020-09-21 00:17:14 +01:00
Richard Davey
1d2a8bc58f
Added fog to shader
2020-09-21 00:16:43 +01:00
Richard Davey
307cbe130f
New Mesh Shader
2020-09-18 17:51:23 +01:00
Richard Davey
9a1b252a11
Use shouldFlush
2020-09-18 17:50:57 +01:00
Richard Davey
0013db3747
Created new Mesh Pipeline
2020-09-18 17:50:20 +01:00
Richard Davey
74f35acad1
Better docs
2020-09-18 16:38:26 +01:00
Richard Davey
5e5b8c0938
The WebGLPipeline.shouldFlush
method now accepts an optional parameter amount
. If given, it will return true
if when the amount is added to the vertex count it will exceed the vertex capacity. The Multi Pipeline has been updated to now use this method instead of performing the comparison multiple times itself.
2020-09-15 11:54:12 +01:00
Richard Davey
6a966e3f3b
Removed interpolationPercentage
parameter from all render methods, as it has never been used.
2020-09-14 15:33:58 +01:00
Richard Davey
3fa0070e50
Now uses white texture and tintEffect mode 1
2020-09-14 15:03:04 +01:00
Richard Davey
81800e0ce2
WebGLRenderer.whiteTexture
is a new property that is a reference to a pure white 4x4 texture that is created during Boot by the Texture Manager. The Multi Pipeline uses this internally for all Graphic, Shape and fill rendering.
2020-09-14 14:44:29 +01:00
Richard Davey
4ade25fc79
No longer read private values for tint
...
The `Multi Pipeline`, `Bitmap Text`, `Render Texture`, `Text`, `TileSprite` and `Camera` now all read the tint values from the public properties instead of the private `_tintTL` etc ones. They also now set the `tintEffect` value directly from the `tintFill` property, removing another conditional check.
2020-09-14 11:05:09 +01:00
Richard Davey
75c5f11aee
Updated shader source RGB to BGR and removed if-else block
...
* The `Single.frag`, `Light.frag` and `Multi.frag` shaders have all been updated so they now read the color value as `outTint.bgr` instead of `outTint.rgb`. This allows the colors to remain in RGB order within the Tint component.
* The `Single.frag`, `Light.frag` and `Multi.frag` shaders have all been updated so they no longer have a 3-way check on the `outTintEffect` value.
2020-09-14 11:02:02 +01:00
Richard Davey
ea0abc4f69
Tidy up the formatting
2020-09-14 09:44:17 +01:00
Richard Davey
e4b1093e72
The WebGLRenderer.resize
and onResize
methods no longer receives or uses the resolution
parameter.
2020-09-12 11:58:08 +01:00
Richard Davey
67e49b515c
The PipelineManager.resize
method along with WebGLPipeline.resize
and anything else that extends them no longer receives or uses the resolution
parameter.
2020-09-12 11:57:16 +01:00
Richard Davey
37a9261ac4
The CanvasRenderer
no longer reads or uses the Game Config resolution property.
2020-09-12 11:56:11 +01:00
Emil Schnedler Vad
e1106a0112
Says webglRender but it is in PipelineManager
2020-09-11 18:44:11 +02:00
Richard Davey
205552d69c
Fix namespaces. Fix #5289
2020-09-10 17:04:56 +01:00
Richard Davey
296dafebf5
No need for gl ref
2020-09-09 13:33:25 +01:00
Richard Davey
da4c387d86
Reference fixes
2020-09-09 13:21:38 +01:00
Richard Davey
6734932a32
Update PipelineManager.js
2020-09-09 13:09:25 +01:00
Richard Davey
7e840b2670
Removed all of the pipeline methods and added the Pipeline Manager instance
2020-09-09 13:05:18 +01:00
Richard Davey
52c2312455
Update PipelineManager.js
2020-09-09 13:05:18 +01:00
Richard Davey
7765016caa
Pipeline constants so we can avoid using strings elsewhere
2020-09-09 13:05:17 +01:00
Richard Davey
d3e82f2d76
The new Pipeline Manager class
2020-09-09 13:05:17 +01:00
Richard Davey
dc99fd03aa
Don't create if vertices already provided. Fix #5280
2020-09-07 16:03:36 +01:00
Richard Davey
5224985e7f
Update BitmapMaskPipeline.js
2020-09-07 16:03:18 +01:00
Richard Davey
d92195a8b8
Default rotation as well
2020-09-02 22:55:51 +01:00
Richard Davey
1562525a51
When using Camera.setRenderToTexture
its zoom
value would be applied twice. Fix #4221
2020-09-02 22:50:27 +01:00
Richard Davey
6aef37572d
WebGLRenderer.previousPipeline
is a new property that is set during a call to clearPipeline
and used during calls to rebindPipeline
, allowing the renderer to rebind any previous pipeline, not just the Multi Pipeline.
...
The `WebGLRenderer.rebindPipeline` method has been changed slightly. Previously, you had to specify the `pipelineInstance`, but this is now optional. If you don't, it will use the new `previousPipeline` property instead. If not set, or none given, it will now return without throwing gl errors as well.
2020-09-01 13:05:31 +01:00
Richard Davey
809b8a41d9
The WebGLRenderer.updateCanvasTexture
method will now set gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL
to true, which should stop issues where you update a Text Game Object, having added a Render Texture or Spine Game Object to the Scene after it, which switches the PMA setting. Fix #5064
2020-08-26 00:19:19 +01:00
Richard Davey
791704febe
WebGLRenderer.finalType
is a new boolean property that signifies if the current Game Object being rendered is the final one in the list.
2020-08-25 18:24:42 +01:00
Richard Davey
de0133e3cc
Spine Game Objects can now be rendered to Render Textures. Fix #5184
2020-08-25 14:11:37 +01:00
Richard Davey
ca99c4564f
Added reset
property to Bind to get new vertex attrib locations
2020-08-25 13:24:56 +01:00
Richard Davey
7d1ad38b4a
Updated shader names
2020-08-25 13:23:59 +01:00
Richard Davey
0cd4d0fc54
Update WebGLRenderer.js
2020-08-21 16:23:04 +01:00
Richard Davey
9a1dc640f8
Fix gl access
2020-08-21 16:17:29 +01:00
Richard Davey
0dd07333af
Updated to use MultiPipeline
2020-08-21 16:14:59 +01:00
Richard Davey
5c39254f36
Testing new config approach
2020-08-21 16:04:26 +01:00
Richard Davey
209b39b38c
New pipeline names and single texture flag
2020-08-21 16:03:29 +01:00
Richard Davey
468c03dfe5
Much better docs and handling of config values
2020-08-21 16:03:07 +01:00
Richard Davey
4b4af50ca9
Quicker return
2020-08-21 16:02:43 +01:00
Richard Davey
37fdde7911
New typedefs for pipeline configs
2020-08-21 16:02:30 +01:00
Richard Davey
600385ac29
A brand new pipeline for single-texture custom pipelines
2020-08-21 16:01:53 +01:00
Richard Davey
57040554ef
Renamed the pipelines to make them less ambiguous and sorted out lots of config properties
2020-08-21 16:01:39 +01:00
Richard Davey
8f5ee5391f
Removed redundant consts
2020-08-21 15:59:41 +01:00