Re: somewhat tangential...look what exists for declarative 2D

On Sep 27, 2011, at 12:13 PM, Kristian Sons wrote:

> Hi Sandy,
> very impressing library with nice results. I'm sure it could be adapted 
> to 3D.

Yes it's a very cool library, but very dependant on SVG I think...I would not assume it could be adapted to 3D easily that might imply a case
for SGV3D ;-)
> I would like to take this opportunity to discuss about "Declarative 3D" 
> use cases:
> The nice design of libraries like these (with similar concepts in other 
> like jQuery and Prototypes) leverages some nice features of JavaScript 
> (functional, closures etc). This makes it easy (and fun) to develop on a 
> higher abstraction layer.
> But this also shows, that we should be careful, to not focus too much on 
> the easiness of use when we argue for a declarative 3D approach. Let me 
> give an example:
> If you consider use case UC101[1]. Excluding the fact that the geometry 
> should be posted to a blog, it means to create a Box with a certain 
> color on a canvas with a certain size. Using a nice WebGL library and a 
> canvas, this could be expressed like this:
>"myCanvas").appendBox(1, 1, 1)
>      .diffuseColor(rgba(58,52,45,1));
I think the library Three.js functions somewhat like this, but not sure. Three.js does seem to be used a good bit though.
> Adding "onmouseover" and "onclick" would be just as easy.
> You know that I'm committed to a declarative approach, but the example 
> shows three things:
> 1. We should not focus on easiness for trivial examples, because it's 
> not necessarily easier than API+Library. I think that reverses on more 
> complex scenes, as the handling of objects not in a uniform structure 
> (DOM) will be harder to handle.

OK ease of use for complex scenes, is I think important. Not so much traditional ease of use but ease of understanding. I think it's important
for "developers" who should be end users to understand what's going on. I also think that putting the geometry as part of the DOM is the big win here.
And the reason it's a win is that there are lots of libraries and tools to manipulate the DOM.
> 2. The essentail point of use case UC101 is the ability to post 3D to a 
> blog (the blog provider will not allow you to include arbitrary JS 
> libraries)

If the declarative functionality is built into the browser and is a first class citizen then users could post the 3D to a blog. I'm a little concerned about getting from here to there. You are correct that a blog provider will probably not allow arbitrary JS, so how do we demonstrate the capability first, before everything is built in. The existing mechanism of including JS libraries may have to suffice.
> 3. These powerful functionality given, we don't have to solve everything 
> in the declarative part. We should provide the building blocks and 
> delegate everything else to libraries. This keeps the format lean and 
> the chance higher to get it implemented natively one day.

I like the idea of keeping things simple, that's for sure. And yes not solving everything makes sense but of course we have to solve enough to be useful.
> I know that point 2 and 3 are a little contradictory on first sight. But 
> the functionality in a foreign non-JS environment could be reduced 
> compared to a full JS environment. This is just the same for HTML.

Do we really need to worry about a non-JS environment? Doesn't every web browser these days have a robust JS interpreter?

> What do you think?
Not sure I've added anything useful here..but it's a fun discussion! ;-)

> Best,
>   Kristian
> [1] 
> Am 23.09.2011 19:53, schrieb Sandy Ressler:
>> Hi folks, in our quest to develop use cases for 3D I would suggest
>> looking at what has happened in the 2D world.
>> SVG and a few other aspects of HTML5 currently provide declarative 2D.
>> One amazing example of what people have done with this is a library
>> called d3.js (from Mike Bostock)
>> go to:
>> to see the overall set of examples and go to:
>> to see an amazing slide
>> show (in this slide show you have to hit the right arrow key to advance
>> the slide...and you can interact with most of the slides's not
>> obvious)
>> Personally I think we should strive to be able to create web
>> visualizations like this but using declarative 3D...someday ;-)
>> Sandy
>> Sandy Ressler
>> High Performance Computing and Visualization Group
>> National Institute of Standards and Technology
>> 100 Bureau Drive, STOP 8911
>> Gaithersburg MD, 20899
>> (301) 975-3549 Fax: (301) 975-3218
>> <>
> -- 
> ________________________________________________________
> Kristian Sons
> Deutsches Forschungszentrum für Künstliche Intelligenz GmbH, DFKI
> Agenten und Simulierte Realität
> Campus, Geb. D 3 2, Raum 0.77
> 66123 Saarbrücken, Germany
> Phone: +49 681 85775-3833
> Phone: +49 681 302-3833
> Fax:   +49 681 85775–2235
> Geschäftsführung: Prof. Dr. Dr. h.c. mult. Wolfgang Wahlster (Vorsitzender)
> Dr. Walter Olthoff
> Vorsitzender des Aufsichtsrats: Prof. Dr. h.c. Hans A. Aukes
> Amtsgericht Kaiserslautern, HRB 2313
> ________________________________________________________

Sandy Ressler
High Performance Computing and Visualization Group
National Institute of Standards and Technology
100 Bureau Drive, STOP 8911
Gaithersburg MD, 20899
(301) 975-3549 Fax: (301) 975-3218

Received on Tuesday, 27 September 2011 18:12:39 UTC