New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Emscripten support with glfw3 (and shaders) demo at www.cwkx.com/nuklear #164

Merged
merged 2 commits into from Jul 6, 2016

Conversation

Projects
None yet
5 participants
@cwkx
Contributor

cwkx commented Jun 13, 2016

Hi, I added Emscripten support with glfw3 (and shaders), with a demo at www.cwkx.com/nuklear

  • to compille, use "emcc main.c -o index.html -s USE_GLFW=3" or use "node build.js" once emscripten is installed and added to path.
  • You can get index.js down to 450kb with -Oz but this requires a webserver for the index.html.mem whereas with -O0 it runs out of the box
  • the main changes to make it work were some rewrite of the shaders, and replacement of glMapBuffer with glBufferSubData, and some restructuring (adding meta to device struct) as VAOs aren't supported by WebGL.
@lieff

This comment has been minimized.

Show comment
Hide comment
@lieff

lieff Jun 14, 2016

Contributor

Additional compiler switch -I../.. is needed for #include "nuklear.h".

Contributor

lieff commented Jun 14, 2016

Additional compiler switch -I../.. is needed for #include "nuklear.h".

@lieff

This comment has been minimized.

Show comment
Hide comment
@lieff

lieff Jun 18, 2016

Contributor

Works great!

Contributor

lieff commented Jun 18, 2016

Works great!

@dumblob

This comment has been minimized.

Show comment
Hide comment
@dumblob

dumblob Jun 22, 2016

Collaborator

Thanks, it's nice to see Nuklear working in a web browser!

By the way, do you also experience window grab exchange or even both-windows-at-the-same-time-grab when quickly moving one window back and forth while ensuring the mouse pointer is crossing another window's title bar (disregarding whether the grabbed window is overlapping or underlapping)?

@vurtun do you happen to have any idea why this could happen?

Collaborator

dumblob commented Jun 22, 2016

Thanks, it's nice to see Nuklear working in a web browser!

By the way, do you also experience window grab exchange or even both-windows-at-the-same-time-grab when quickly moving one window back and forth while ensuring the mouse pointer is crossing another window's title bar (disregarding whether the grabbed window is overlapping or underlapping)?

@vurtun do you happen to have any idea why this could happen?

@paulsapps

This comment has been minimized.

Show comment
Hide comment
@paulsapps

paulsapps Jun 22, 2016

Mouse wheel scrolling seems to be inverted?

paulsapps commented Jun 22, 2016

Mouse wheel scrolling seems to be inverted?

@vurtun vurtun merged commit e5ce2de into vurtun:master Jul 6, 2016

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
@dumblob

This comment has been minimized.

Show comment
Hide comment
@dumblob

dumblob Aug 4, 2016

Collaborator

@cwkx could you please update the demo on www.cwkx.com/nuklear (as the bug mentioned in #164 (comment) should be fixed by 2b1c2ca )?

Collaborator

dumblob commented Aug 4, 2016

@cwkx could you please update the demo on www.cwkx.com/nuklear (as the bug mentioned in #164 (comment) should be fixed by 2b1c2ca )?

@dumblob

This comment has been minimized.

Show comment
Hide comment
@dumblob

dumblob Aug 16, 2016

Collaborator

@cwkx I can see that you're working hard on the 3D curve paper, but could you please state whether you want to further develop/maintain the emscripten demo? @vurtun decided to remove it in cae6005 because of missing response.

Collaborator

dumblob commented Aug 16, 2016

@cwkx I can see that you're working hard on the 3D curve paper, but could you please state whether you want to further develop/maintain the emscripten demo? @vurtun decided to remove it in cae6005 because of missing response.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment