Skip to content

gpujs/gpu-mock.js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gpu-mock.js

A simple mocker for testing threaded development.

GPU testing

GPU testing should be easy, but it isn't... ur, uh, wasn't. This lib aims to resolve that. By testing with simple javascript that is transpiled to GPU code, we can have the best of both worlds. A mature debugging environment (javascript), and an accelerated environment (glsl).

Install

npm i gpu-mock.js --saveDev

Use

import { gpuMock } from 'gpu-mock.js'

const testKernel = gpuMock(myKernelFunction, gpuJsOptions);

const results = testKernel();

Why

gpu.js, and further the GPU, do a lot under the hood that can make debugging challenging. gpu-mock.js provides a pure and simple javascript environment for testing the functions that are planned to be used with gpu.js.

About

A simple mocker for testing threaded development

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published