> On Oct 18, 2013, at 3:18 AM, Eric Reynolds <[email protected]> 
> wrote:
> 
> That sounds great, I am just wondering though, that would require you to 
> redevelop a library of widgets to be able to set up a GUI, so why not use 
> HTML?

I actually do.  I have a set of classes which model Keyboard, Mouse, Touchpad, 
Display, virtual Screen (a screen can span multiple displays) and the like. 
These either work in browser or proxy events to the server. 

I don't use the DOM as it would require synchronization between two display 
models, server side vs client. So the client doesn't get a scene graph, it 
merely gets a function which can render the scene. I then use a render pipeline 
to composite multiple scenes. I used to build video game engines and this is 
all pretty standard stuff minus the network and client and lag. 

> How do you do the code caching and hot fixing? Have you packaged your code 
> into a module on npm?

No I literally send the function definitions as JSON blobs:

[ "uuid", "arg1", ..., "argn", " return arg1 + 1"]

The on message handler decodes the JSON and uses the UUID to update or create 
the cache entry. Function.prototype.constructor is applied to the slice of the 
remainder of the array. And the function gets added to the render pipeline.

So it is full MVC, just the V is a render pipeline function, the C are the 
device abstraction layer which sends user messages to the views and models, and 
all of the models tend to reside server side. 

There might see to be more complexity than a typical web app, but the code is 
simpler and I get excellent frame rates on mobile. 

Hiding latency of both the input layer and the eventually consistent data store 
are the real tricky bits :). 

Dave

-- 
-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to