60 Commits

Author SHA1 Message Date
Robert Plummer
d51da85371 fix: turn off debug in test 2019-04-21 12:03:04 -04:00
Robert Plummer
b60e571646 fix: 8 and 16 bit packing when using single precision float
fix: 2,3,4 array output render strategies
fix: Add deprecation handling
fix: Add addArgument and addConstant tests for webgl2
fix: remove floatTextures as a property
2019-04-21 12:02:34 -04:00
Robert Plummer
00ee2ba982 feat: Refactor dimensional values and expose the bitRatio all the way to the function node
fix: Added test suite for arrays and inputs for webgl and webgl2
fix: Rename "floatOutput" feature to "precision".  Values can be "unsigned" or "single"
fix: Add input and Input to typings
fix: Use Int32Array for input.size
2019-04-20 09:59:49 -04:00
Robert Plummer
e778dc1519 fix: Eliminate need for using decode inside fragment shader
fix: Auto float handling
fix: this.texSize from early setting in validateSettings
fix: Add compiledFragmentShader and compiledVertexShader as props in kernel
feat: Add setOptimizeFloatMemory in kernel.js
fix: Add some typings
fix: Simplify how dimToTexSize gets dimensions
fix: Simplify createKernelMap tests
fix: Add utils tests
fix: Simplify issue 267 tests
fix: Alter issue 279 tests, and add TODO

1 Broken test left
2019-04-16 08:37:57 -04:00
Robert Plummer
58d77be9a7 fix: Remove erroneous channel and index division in getImage2D of webgl1
fix: Remove some debugging code
fix: Build and beautify everything (was off whilst doing some mad debugging earlier)
2019-04-12 14:09:05 -04:00
Robert Plummer
ee7baf70ba fix: Array handling (2,3,4) for webgl2 & webgl1 (headlessgl next)
fix: Float handling
feat: added `optimizeFloatMemory` to better exemplify what it does and replace `floatTextures` and its voodoo in webgl2
feat: end to end strong type detection
Note: added a bunch of TODO's this is just a good resting point.
2019-04-11 19:41:58 -04:00
Robert Plummer
1e60084020 feat: Full type inference (this is a HUGE feature)
feat: Add mandelbulb.html example
fix: Bump and build
2019-03-19 19:51:03 -04:00
Robert Plummer
9540340751 fix: Fix floatTextures support test
fix: Rename `WebGLKernel._formatArrayTransfer()` to `WebGLKernel.formatArrayTransfer()` because it is used in more than just this class
fix: Add `HeadlessGL.features.isTextureFloat`
fix: Add `HeadlessGL.getIsTextureFloat()`
fix: Add operation to delete `HeadlessGLKernel.extensions.WEBGL_draw_buffers`
fix: Remove `assert.throws` from Issue #91 test
fix: Add "features/float-output-textures.js" back to all.html test
fix: Bump version number and build
2019-03-19 08:43:58 -04:00
Robert Plummer
4aa08ca393 fix: Casting for all non-float arguments used with Math.fn()
fix: Greater than, less than evaluation when comparing an integer with a literal that is a float, try not to cast left, but rather cast left to right
fix: Constants that do not have a type defined should fail
fix: Don't prevent "random" as a native function name
fix: Allow Texture constructor to inherit instance of GPU for easy .toArray()
fix: Texture constructor as settings object for easier understanding of order input
fix: Typescript corrections for Texture
fix: Bump headless-gl version to that of Multiple Render Targets
2019-03-17 22:12:09 -04:00
Robert Plummer
6050e6a8a6 fix: When literals are returned from kernel, freeze their type
feat: Parse GLSL and get return type and argument types
feat: Properly look up native function return types and cast if needed
feat: Properly look up native function argument types and cast if needed
fix: Move this.chooseKernel() to beginning of GPU instantiation

As well as test all the above
2019-03-13 12:36:19 -04:00
Robert Plummer
5f59354219 fix: this.thread, and this.output type handling, and block statements 2019-02-18 10:55:30 -05:00
Robert Plummer
cf5a358422 fix: Got 100% unit tests in chrome, ff, safari, and node. 2019-02-07 19:08:19 -05:00
Robert Plummer
a586c0d96d fix: constants image early throw for webgl 2019-02-06 09:18:09 -05:00
Robert Plummer
2b6802e292 fix: astBinaryExpression unit tests
Simplify internal/kernel.js tests
2019-02-05 22:13:44 -05:00
Robert Plummer
f48409cc56 fix: Web side tests
Also cleanup moving methods around for reuse and so code can be more concise.
Removed some older references, where now we use `this.thread.x` or `this.output.x`.
Removed some older methods we no longer use (astFunctionPrototype).
Removed some overloaded functions from webgl1 and webgl2 glsl.  We no longer need them.
Removed some references to `=== null` in favor of truthy.  `if (undefined === null)` is true, and can lead to unexpected results, where we really wanted truthy, and is simpler to write.
2019-02-05 21:17:20 -05:00
Robert Plummer
630bd94ead feat: Completely new type checking system, and refined state management 2019-02-04 19:46:55 -05:00
Robert Plummer
82e4966551 feat: v2.0.0rc1
Cleanup and add random support (seeded by... Math.random()!)
I went through api and cleaned it up considerably
2019-01-31 18:24:25 -05:00
Robert Plummer
abdb7a66f9 feat: Finally add the missing json with gpu-core feature!
And add unit tests
2019-01-29 23:41:05 -05:00
Robert Plummer
8bf362ad9a feat: No failing tests locally, only skipping and passing
Also:
feat: Typescript typings
feat: api cleanup and exports
feat: removal of building for node, only browser
2019-01-29 21:41:21 -05:00
Robert Plummer
920aaf67d9 feat: Massive simplification and refactor for v2 2019-01-26 21:47:26 -05:00
Robert Plummer
bafac7831e feat: Huge rewrite for v2 2019-01-24 22:18:22 -05:00
Robert Plummer
8173ed7f62 fix: Migrating tests and ensuring they act same on all backends 2019-01-19 08:46:42 -05:00
Robert Plummer
3005828b86 fix: Migrating tests, and build
This was a good resting point.
Delete unneeded files.
2019-01-18 08:32:10 -05:00
Robert Plummer
c234e37942 fix: cpu canvas check 2019-01-17 15:24:37 -05:00
Robert Plummer
87e2be5fba feat: Migrating to use gl, bump version number
Not ready yet, but close.  Need build scripts from headless-gl upstream.
2019-01-04 10:29:45 -05:00
Robert Plummer
b577c1a193 fix: CPU transpilation issue for type management
Refactored tests to test webgl, webgl2, and cpu individually and more generically.

Fixes #392
2018-11-01 14:17:08 -04:00
Robert Plummer
d765de4cd0 fix: Upgrade remaining non-javascript like types
To be referenced in same way.
Simplify FunctionNode.
Update documentation to be more straightforward.
Remove code no longer needed from WebGL2 FunctionNode.
2018-10-30 08:14:01 -06:00
Robert Plummer
2599966e7c fix: Better defining internal lookups of types and documentation 2018-10-28 14:05:44 -04:00
Robert Plummer
d561fcf228 feat: Migrate to use type strings for arguments and returnType 2018-10-27 14:46:42 -04:00
Robert Plummer
37c9a04bd5 fix: Lookup types from function nodes and use those when transpiling 2018-10-26 19:47:03 -04:00
Robert Plummer
4f26639a59 feat: Lay groundwork for deep type detection from functions
This first pass starts with static values and gives us the mvp of type setting/detection from other functions.
2018-10-26 19:16:50 -04:00
Robert Plummer
0e4c04917a feat: Update for offscreen canvas and retool for cleaner CPU kernel backend
fix toString for kernels as well
Added documentation
Updated release year
2018-10-24 14:12:12 -04:00
Sandeep Mistry
aad86a86ab Add test for Worker + Offscreen canvas 2018-09-30 11:04:54 -04:00
Robert Plummer
d4468e33fc feat: Provide a means of obtaining the color texture directly 2018-09-11 15:34:23 -04:00
Robert Plummer
449b2903b3 Merge remote-tracking branch 'upstream/develop' into develop 2018-09-11 15:12:28 -04:00
viziionary
e9de3b031b Exposed error 2018-09-10 14:47:41 -05:00
Robert Plummer
e2996f8229 bump version number
remove some unneeded console.log messages
remove commented out utility line
2018-09-05 16:55:00 -04:00
Nick Hingston
72e65b206e Merge branch 'develop' into 361-multi-dimensional-output-slow 2018-09-05 21:05:13 +01:00
Nick Hingston
30e5ddb37a make splitArray performant and fix test cases 2018-09-05 21:04:23 +01:00
Robert Plummer
e59452aa98 fix: add sampler2DArray where missing
fix: use highp in webgl2
fix: unit tests to to test for exception in webgl1
2018-09-02 11:28:44 -04:00
viziionary
8b1f51ddac Mid progress update, supporting all constant types 2018-09-02 08:31:30 -05:00
Robert Plummer
91833f531d fix: Make images work with constants and CPU
fix: Allow for pixel.r, pixel.g, pixel.b, pixel.a
2018-09-01 15:30:37 -04:00
viziionary
f5951ccb32 Mid progress update 2018-09-01 08:36:34 -05:00
viziionary
8a893297a8 Unit testing and feature completion 2018-08-30 18:30:37 -05:00
Nick Hingston
2450d4cdd4 fix webgl leaks on all test cases 2018-07-30 21:11:56 +01:00
Nick Hingston
462e4d510f auto check if integer division bug exists 2018-07-26 09:05:08 +01:00
Nick Hingston
98e1bf7688 fix integer division issues on some cards 2018-07-25 18:14:06 +01:00
Robert Plummer
8ee7428e35 Closes #350 - Add Float32Array support on CPU fallback 2018-07-24 15:16:28 -04:00
Robert Plummer
b7e9dfc47b Fix unit test, and bump release numbers 2018-07-12 16:29:36 -04:00
Robert Plummer
a8d5d02c79 Minor fix for 3d kernel maps and test 2018-07-11 18:54:01 -04:00