the state of webdynamo: an agentcubes web api scott keller erin rowland stuart reed michael wally...
DESCRIPTION
Focus of this Presentation Project Overview GUI Architecture Demonstrations Erin Rowland3TRANSCRIPT
1
WebDYNAMO
The State of WebDynamo:An AgentCubes Web API
Scott KellerErin RowlandStuart Reed
Michael WallyGeorge McCabe
dy· na· mo: (n.) A generator
Erin Rowland
2Erin Rowland
Scott Keller
Erin Rowland
Stuart Reed
Michael Wally
George McCabe
T h e W e b D y n a m o Te a m
W e b DY N A M O
3
Focus of this PresentationProject OverviewGUIArchitectureDemonstrations
Erin RowlandW e b DY N A M O
4
Focus of this PresentationProject Overview
◦Senior Projects Class◦The Problem◦Our Solution
GUIArchitectureDemonstrations
Erin RowlandW e b DY N A M O
5
Senior Projects ClassComputer Science Capstone13 Teams … 61 studentsIndustry ProjectsEntertainment ProjectsEducational Projects
◦Health Care Education using Second-Life University of Colorado Denver College of Nursing
◦Science on a Sphere Craft Technologies Group
Erin RowlandW e b DY N A M O
6
The Problem:AgentCubes Needs
Improvement
Portability (Multi-Platform)AccessibilityCollaboration
W e b DY N A M O George McCabe
7
The Problem:Portability
AgentSheets (2D) is available for Windows and Mac operating systems
However, AgentCubes (3D) is currently only available for Mac OS X
AgentCubes is currently not available to the public (in development phase)
George McCabe
8
The Problem:Accessibility
AgentSheets and AgentCubes Require User to Download and Install the Software
Work done in program restricted to user’s computer
W e b DY N A M O George McCabe
9
The Problem:Collaboration
Projects cannot easily be shared with others without downloads, which restricts inspiration
Collaboration on projects requires all participants to use the same machine with the program installed
George McCabe
10
Solution:Render 3D in a Web Browser
API of JavaScript Calls Implement WEUP Behavior and Agents
Graphics in O3DWebGL (In Development) an Option
Interact with WEUP and the “Dark Tunnel” Compiler
Allows Users to Access Worksheet From any Computer With Internet Access
W e b DY N A M O George McCabe
11
The Solution:Portability
Use O3D Graphics API
O3D works easily on multiple operating systems
O3D works easily on multiple web
browsers
Allows availability to the publicGeorge McCabe
12
The Solution:Accessibility
Only download required is the O3D
Plug-in for the web browser
Work done in a worksheet can be accessed from any computer with internet access and the O3D Plug-in
George McCabe
13
The Solution:Collaboration
Sharing projects with other users is easy, since the projects will be stored online in a database
Users can easily access other projects and become inspired by them
Multiple users can work together on a project from any location with internet access
George McCabe
14
Solution: (cont’d)Other Components
◦ Web End-User Programming◦ GUI Allows Users to Create Agents and Define
Their Behavior◦ Creates XML files to Store Agents, Behaviors,
and the SceneW e b DY N A M O George McCabe
WEUP
15
Solution: (cont’d)Other Components
WebDynamo is an O3D Version of the AgentCubes Worksheet◦Tools Allow Interaction With the Scene
Draw and Manipulate Object Instances Pan and Zoom Camera
W e b DY N A M O George McCabe
16
Solution: (cont’d)Other Components
“Dark Tunnel” CompilerUniversity of Lugano in
SwitzerlandGenerates JavaScript
Calls API Functions Defined by WebDynamo
W e b DY N A M O George McCabe
17
Focus of this PresentationProject OverviewGUI
◦Worksheet◦Toolbar
ArchitectureDemonstrations
Stuart ReedW e b DY N A M O
18
WebDynamo GUIO3D Worksheet
W e b DY N A M O Stuart Reed
Scene
Toolbar
Agent
19
AgentCubes Worksheet ToolsJavaScript Handlers for
Keyboard and Mouse InputCalls Method for Active Tool
WebDynamo GUI Toolbar
W e b DY N A M O Stuart Reed
20
WebDynamo GUI Toolbar
W e b DY N A M O Stuart Reed
Simulation
Runtime Controls
•Stop•Run•Step
21
WebDynamo GUI Toolbar
W e b DY N A M O Stuart Reed
Agent Controls
•Se lec t•Draw•Erase•Hand•Hammer
22
WebDynamo GUI Toolbar
W e b DY N A M O Stuart Reed
Camera Controls
•Pan•Zoom•Rotate
23
WebDynamo GUI Toolbar
W e b DY N A M O Stuart Reed
Worksheet
Controls
•Ref resh•Load•Save•C lear
24
Focus of this PresentationProject OverviewGUIArchitecture
◦Conceptual Diagram◦Requirements◦Model-View-Controller
Demonstrations
Michael WallyW e b DY N A M O
25
WebDynamo Conceptual Diagram
XML
Definitions
API
G
U
I
O3D
VAT
XML
Rules
CompilerUniversity of
Lugano
WEUP
GUIOPEN
JavaScript
Web
Dynamo
W e b DY N A M O Michael Wally
26
Compiler, University of Lugano
Calls WebDynamo JavaScript APIParses XML Behavior files
W e b DY N A M O
CompilerUniversity of
Lugano
Michael Wally
27
WEUP GUI
Write XML File Attributes for Project
Communicate With WebDynamo Input
W e b DY N A M O
WEUP
GUI
Michael Wally
28
WebDynamo
API and GUI written in JavaScript
API Methods Designed to Handle External Commands
GUI Rendered Using Google’s O3D to Imitate AgentCubes.
W e b DY N A M O
API
G
U
I
O3D
Web
Dynamo
Michael Wally
29
Environmental Requirements
Software / Development Environment◦ Supported Browsers:
Chrome, Firefox 3, Safari 4, IE 8◦ Supported Operating Systems:
Windows XP, Mac OS X, Linux◦ Implement API in JavaScript and O3D
W e b DY N A M O Michael Wally
30
Environmental Requirements
Hardware Environment◦ Windows:
x86 CPU, DX9-compatible GPU with VS 2.0 and PS 2.0 support
◦ Mac: Any Intel Mac (Unsupported GPUs Will Use
SW rederer)
W e b DY N A M O Michael Wally
31
Functional RequirementsRead/Write XML
◦Keep Track of Object AttributesAPI functions
◦Condition and Action EventsO3D Scene RenderingWorksheet GUI
◦Manipulate Agents◦Save and Load Simulations
W e b DY N A M O Michael Wally
32
Architecture
W e b DY N A M O
Simulation Functions
Editing and Camera Tools
Controller
View (Worksheet)Model
User InputWebDynamo
JavaScript Functions
Parse and Return XML Data
O3D JS
Object State
Calls JS API Functions
WEUP
Stores XML Object Attributes
Scott Keller
33
Architecture
W e b DY N A M O
Simulation Functions
Editing and Camera Tools
ControllerWebDynamo
JavaScript Functions
Parse and Return XML DataCalls JS API Functions
WEUP
Stores XML Object Attributes
Controller◦WebDynamo JavaScript Handlers
Editing and Camera Tools Simulation Functions (Stop, Run, Step)
◦Parse and Return XML Data WEUP and API Method Calls
Scott Keller
34
Architecture
W e b DY N A M O
Controller
Model
Object State
Model◦Maintain Agent Attributes◦Class Definitions
Agent, Method, Rule
Scott Keller
35
Architecture
W e b DY N A M O
Agent Class◦Variables
Depiction (Array), Coordinates, Methods (Array)◦Methods
addDepiction, getDepiction, addAMethod, testMethod
Scott Keller
class Agent {
String name; int x,y,z; int transform; depiction = [depic1, depic2, ...];methods = [whileRunning, doStuff, ...];
addDepiction(depic); getDepiction(); addMethod(); checkMethods();
. . .
}
36
Architecture
W e b DY N A M O
Method Class◦Variables
Rules (Array), condState (Array)◦Methods
testMethodScott Keller
class Method {
rules = [rule1,rule2,...];addRule(); getRule(); checkRules();
. . .
}
37
Architecture
W e b DY N A M O
Rule Class◦Variables
Conditions (Array), Actions (Array)◦Methods
Implement, testConditions, implementActions
Scott Keller
class Rule {
conditions = [cond1,cond2,...]; actions = [action1,action2,...];
addCondition(); addAction(); check(); testConditions(); doActions();
. . .
}
38W e b DY N A M O Scott Keller
class Rule
function see(direct,agent) { var i=this.x; var j=this.y; var k=this.z;
switch(direct) { //i+1;j+1 case 1: if(myBoard[i+1][j+1][k+1].pic == agent.pic) return true; break; case 2: if(myBoard[i+1][j+1][k].pic == agent.pic) return true; break; case 3: if(myBoard[i+1][j+1][k-1].pic == agent.pic) return true; break; ... default: } return false; }
function move(direct) { var i=this.x; var j=this.y; var k=this.z;
switch(direct) { case 1: if(myBoard[i+1][j+1][k+1] == 0) myBoard[i+1][j+1][k+1] = this; myBoard[i][j][k] = 0; g_transforms[this.transform].translate(1,1,1); return true; break; case 2: if(myBoard[i+1][j+1][k] == 0) myBoard[i+1][j+1][k] = this; myBoard[i][j][k] = 0; g_transforms[this.transform].translate(1,1,0); return true; break; ... } return false; }
class Agent class Method
39
Architecture
W e b DY N A M O
Controller
View (Worksheet)
User Input
O3D JS
View◦WebDynamo Worksheet
Input (Toolbar and Scene)
Output (O3D JavaScript)
Scott Keller
40
Focus of this PresentationProject OverviewGUIArchitectureDemonstrations
◦GUI◦Methods
Stuart ReedW e b DY N A M O
41
SummaryProject OverviewGUIArchitectureDemonstrations
Michael WallyW e b DY N A M O
42W e b DY N A M O
Questions?