Git Product home page Git Product logo

node-wpe-webgl's People

Contributors

albertd avatar basvanmeurs avatar goruklu avatar modeveci avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

node-wpe-webgl's Issues

Can't init GLEW

on Raspberry PI (node v8.9.1) I'm getting the following:

(Raspberry PI Zero W)
GL enabled
GPU mem set to 256Mb

initializing GLEW
No protocol specified
/home/smirza/zap-dash/node_modules/wpe-webgl/gles2.js:11
    gles2.init(width, height, fullscreen, title);
          ^

RangeError: Can't init GLEW

    at Object.init (/home/smirza/zap-dash/node_modules/wpe-webgl/gles2.js:11:11)
    at Object.<anonymous> (/home/smirza/zap-dash/index.js:7:18)
    at Module._compile (module.js:635:30)
    at Object.Module._extensions..js (module.js:646:10)
    at Module.load (module.js:554:32)
    at tryModuleLoad (module.js:497:12)
    at Function.Module._load (module.js:489:3)
    at Function.Module.runMain (module.js:676:10)
    at startup (bootstrap_node.js:187:16)
    at bootstrap_node.js:608:3

here is the source code (slightly different from readme example)

const webgl = require('wpe-webgl');
const process = require('process');


let continueLooping = true;
const options = { width: 1280, height: 720, fullscreen: true };
const gl = webgl.init(options);

const end = (new Date().getTime()) + (10 * 1000);

const render = () => {
  const now = new Date().getTime();

  gl.clearColor(0, 1.0, 1.0, 0.0);

  // Set the viewport
  gl.viewport(0, 0, 640, 480);

  // Clear the color buffer
  gl.clear(gl.COLOR_BUFFER_BIT);

  // Do other GL-related stuff here.

  webgl.nextFrame(true /* Use false to prevent buffer swapping */);
  if (continueLooping) {
    process.nextTick(render);
  }

  if (now > end) {
    process.exit(0);
  }
}

render();

unimplemented properties

the following WebGLRenderingContext properties are unimplemented:

readonly drawingBufferHeight: number;
readonly drawingBufferWidth: number;

Module did not self-register

On Raspberry Pi 3 with node 8.9.4, jessie:

module.js:672
  return process.dlopen(module, path._makeLong(filename));
                 ^

Error: Module did not self-register.
    at Object.Module._extensions..node (module.js:672:18)
    at Module.load (module.js:556:32)
    at tryModuleLoad (module.js:499:12)
    at Function.Module._load (module.js:491:3)
    at Module.require (module.js:587:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (/usr/src/app/node_modules/wpe-webgl/gles2.js:1:75)
    at Module._compile (module.js:643:30)
    at Object.Module._extensions..js (module.js:654:10)
    at Module.load (module.js:556:32)

gpu_mem is set to 196 and the results are the same with the new graphics driver (dt_overlay = vc4-kms-v3d)

windows installation fails:

PS C:\play\nodegl> yarn add -D wpe-webgl
yarn add v1.5.1
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...
[1/1] โ  wpe-webgl: not ok
error An unexpected error occurred: "C:\\play\
odegl\
ode_modules\\wpe-webgl: Command failed.
Exit code: 1
Command: C:\\WINDOWS\\system32\\cmd.exe
Arguments: /d /s /c node-gyp rebuild
Directory: C:\\play\
odegl\
ode_modules\\wpe-webgl
Output:
C:\\play\
odegl\
ode_modules\\wpe-webgl>if not defined npm_config_node_gyp (node \"C:\\Program Files\
odejs\
ode_modules\
pm\\bin\
ode-gyp-bin\\\\..\\..\
ode_modules\
ode-gyp\\bin\
ode-gyp.js\" rebuild )  else (node \"\" rebuild )
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | win32 | x64
gyp info spawn C:\\Python27\\python.EXE
gyp info spawn args [ 'C:\\\\Program Files\\\
odejs\\\
ode_modules\\\
pm\\\
ode_modules\\\
ode-gyp\\\\gyp\\\\gyp_main.py',
gyp info spawn args   'binding.gyp',
gyp info spawn args   '-f',
gyp info spawn args   'msvs',
gyp info spawn args   '-G',
gyp info spawn args   'msvs_version=auto',
gyp info spawn args   '-I',
gyp info spawn args   'C:\\\\play\\\
odegl\\\
ode_modules\\\\wpe-webgl\\\\build\\\\config.gypi',
gyp info spawn args   '-I',
gyp info spawn args   'C:\\\\Program Files\\\
odejs\\\
ode_modules\\\
pm\\\
ode_modules\\\
ode-gyp\\\\addon.gypi',
gyp info spawn args   '-I',
gyp info spawn args   'C:\\\\Users\\\\piersh.DFCN\\\\.node-gyp\\\\9.9.0\\\\include\\\
ode\\\\common.gypi',
gyp info spawn args   '-Dlibrary=shared_library',
gyp info spawn args   '-Dvisibility=default',
gyp info spawn args   '-Dnode_root_dir=C:\\\\Users\\\\piersh.DFCN\\\\.node-gyp\\\\9.9.0',
gyp info spawn args   '-Dnode_gyp_dir=C:\\\\Program Files\\\
odejs\\\
ode_modules\\\
pm\\\
ode_modules\\\
ode-gyp',
gyp info spawn args   '-Dnode_lib_file=C:\\\\Users\\\\piersh.DFCN\\\\.node-gyp\\\\9.9.0\\\\<(target_arch)\\\
ode.lib',
gyp info spawn args   '-Dmodule_root_dir=C:\\\\play\\\
odegl\\\
ode_modules\\\\wpe-webgl',
gyp info spawn args   '-Dnode_engine=v8',
gyp info spawn args   '--depth=.',
gyp info spawn args   '--no-parallel',
gyp info spawn args   '--generator-output',
gyp info spawn args   'C:\\\\play\\\
odegl\\\
ode_modules\\\\wpe-webgl\\\\build',
gyp info spawn args   '-Goutput_dir=.' ]
'pkg-config' is not recognized as an internal or external command,\r
operable program or batch file.\r
gyp: Call to 'pkg-config glesv2 egl --libs --silence-errors | grep bcm || true' returned exit status 255 while in binding.gyp. while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onCpExit (C:\\Program Files\
odejs\
ode_modules\
pm\
ode_modules\
ode-gyp\\lib\\configure.js:336:16)
gyp ERR! stack     at ChildProcess.emit (events.js:180:13)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:209:12)
gyp ERR! System Windows_NT 10.0.16299
gyp ERR! command \"C:\\\\Program Files\\\
odejs\\\
ode.exe\" \"C:\\\\Program Files\\\
odejs\\\
ode_modules\\\
pm\\\
ode_modules\\\
ode-gyp\\\\bin\\\
ode-gyp.js\" \"rebuild\"
gyp ERR! cwd C:\\play\
odegl\
ode_modules\\wpe-webgl
gyp ERR! node -v v9.9.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok".
info If you think this is a bug, please open a bug report with the information provided in "C:\\play\
odegl\\yarn-error.log".

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.