forked from mikeseven/node-webgl
-
Notifications
You must be signed in to change notification settings - Fork 182
add support for using inside Worker (worker_threads module) #151
Copy link
Copy link
Open
Description
Please add support of Worker Threads to native addon.
Currently, trying to use it inside Worker, it produces error:
Error: Module did not self-register.
-----
> Object.Module._extensions..node --- internal/modules/cjs/loader.js:846:18
> Module.load --- internal/modules/cjs/loader.js:672:32
> tryModuleLoad --- internal/modules/cjs/loader.js:612:12
> Function.Module._load --- internal/modules/cjs/loader.js:604:3
> Module.require --- internal/modules/cjs/loader.js:711:19
> require --- internal/modules/cjs/helpers.js:14:16
> bindings --- /aufs/devsave/dev/projects/arfc/node_modules/bindings/bindings.js:112:48
> Object.<anonymous> --- /aufs/devsave/dev/projects/arfc/node_modules/gl/webgl.js:4:35
> Module._compile --- internal/modules/cjs/loader.js:805:30
> Object.Module._extensions..js --- internal/modules/cjs/loader.js:816:10
Related docs: https://github.com/nodejs/node/blob/master/doc/api/addons.md#worker-support
IMHO This is vital since the processing is synchronous and is most likely to be run inside separate thread.
Thanks
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels