SlideShare ist ein Scribd-Unternehmen logo
1 von 18
3D MARINE PORT VISUALIZATION
A LITTLE HISTORY
 ECMAScript aka JavaScript
 Created in mid-90s at Netscape
 Called JavaScript as part of a
marketing deal with Sun.
 Standardized by ECMA.
 Version 6 & 7 are in progress
JAVA VS. JAVASCRIPT
 Similarity: a C style syntax
 OO Model
 JavaScript is prototype-based
 Java is class-based
 Threads?
 Java, yup
 JavaScript has HTML5 Web Worker
 Appeal
 Java looks nice at first, later gets annoying
 JavaScript seems horrible at first, gradually grows on
you
THE IDEA
 Visualize a port terminal with a
ubiquitous UI technology
 Provide some level of user
interaction
 Create platform to explore
additional features
 Concerns?
 Render Loop (FPS)
 UI Interaction
 Network Communication
 Polygon Count
 Scene Size
THE DESIGN
 Leverage THREE.js for 3D Library
 Resources
 3D Models
 Textures
 CSS
 HTML
 JavaScript
 Etc.
 CHE Objects
 Forklifts
 Cranes
 Trucks
 Rail
 Ships
TRUCK OBJECT
 Port.Che.Truck
 Properties:
 _location
 _speed
 _movementVector
 _distanceTraveled
 Methods:
 initRoute()
 setVector()
 makeVisible()
 resetLocation()
I’m a truck!
 Create & extends Object4D “Object”
MODELS & MOVEMENT
RTG Movement
Constraints
OBJECT BREAKDOWN
Actions
- Port.Listeners
- Port.Actions.Quays
- Port.Actions.Rtgs
- Port.Actions.Stackers
- Port.Actions.Triggers
- Port.Actions.Trucks
App
- Port.Cameras
- Port.Yard.Gui
- Port.Yard.Scene
Gear
- Port.Che.Block
- Port.Che.Quay
- Port.Che.Rtg
- Port.Che.Ship
- Port.Che.Stacker
- Port.Che.Truck
Management
- Port.Manager
- Port.Manager.Blocks
- Port.Manager.Quays
- Port.Manager.Rtgs
- Port.Manager.Ships
- Port.Manager.Stacker
- Port.Manager.Trucks
Core
- Port.Core.Object4D
- Port.Core.Container
- Port.Util
- Port.Geometry
- Port.Maths
- Port.Preloader
- Port.Manager.Clock
3rd Party Libraries
- Dat.GUI
- jQuery
- MouseTrap
- OBJMTLLoader
- TrackballControl
- THREE
- Kinetic
INITIALIZATION & THE UI FREEZE
Initialization
Terminatio
n
Process
Input
Simulat
e
Render
animation
loop
1. Load geometry
(Web Worker)
2. Load yard blocks
(Local Storage)
3. Server-Sent Events
4. Initialize user controls
5. Create support geometry
6. Add lights and cameras
7. Initialize Scene
8. The Animation Loop!
THE ANIMATION LOOP
 requestAnimFrame API
 Provides timer loop to animate.
FPS Formula:
1000/(16 + N) fps
 N = callback time in ms
 Callback = 1 ms
FPS is ~60fps
 Callback = 84 ms
FPS is ~10 fps
 Higher FPS is better
Initialization
Terminatio
n
Process
Input
Simulat
e
Render
animation
loop
RENDER CALLBACK
 Scene Setup:
Textures, 4 blocks, 4 trucks, 4 RTGs
Render Time: 1 ms
FPS: 60 FPS
Initialization
Shut down
Process
Input
Simulat
e
Render
animation
loop
60 FPS – 4 Blocks – Render Time <
1ms
RENDER CALLBACK
 Scene Setup:
Flat shaded, 100 blocks
Render Time: 110 ms
FPS: 8 FPS
Initialization
Shut down
Process
Input
Simulat
e
Render
animation
loop
8 FPS – 100 Blocks – Render Time 110ms
BIG PROBLEM – VARIABLE FPS
 More polygons within frustum means
slower
rendering.
 Moving frustum results
in a variable frame rate
 Require another level of
time/movement dilation
to smoothly translate models within the
scene
VARIABLE TWEENING
60
FPS
20
FPS
Variable
VARIABLE FPS
Model Manager
Clock Δ
Quay Crane
Manager
RTG Manager
Stacker Manager
Truck Manager
Ship Manager
Management
1) Check CHE Status
- Moving?
- Stopped?
- Waiting?
2) Assign Vector
3) Translate based upon
clock Δ and CHE
speed
DEMO
 Questions?

Weitere ähnliche Inhalte

Ähnlich wie WebGL visualization of a shipping terminal

Ähnlich wie WebGL visualization of a shipping terminal (20)

[1D6]RE-view of Android L developer PRE-view
[1D6]RE-view of Android L developer PRE-view[1D6]RE-view of Android L developer PRE-view
[1D6]RE-view of Android L developer PRE-view
 
Cape Cod Web Technology Meetup - 2
Cape Cod Web Technology Meetup - 2Cape Cod Web Technology Meetup - 2
Cape Cod Web Technology Meetup - 2
 
Game server development in node.js
Game server development in node.jsGame server development in node.js
Game server development in node.js
 
Analyzing the Performance of Mobile Web
Analyzing the Performance of Mobile WebAnalyzing the Performance of Mobile Web
Analyzing the Performance of Mobile Web
 
Apache Flink - a Gentle Start
Apache Flink - a Gentle StartApache Flink - a Gentle Start
Apache Flink - a Gentle Start
 
Lecture 3 Javascript1
Lecture 3  Javascript1Lecture 3  Javascript1
Lecture 3 Javascript1
 
Comet from JavaOne 2008
Comet from JavaOne 2008Comet from JavaOne 2008
Comet from JavaOne 2008
 
StrongLoop Overview
StrongLoop OverviewStrongLoop Overview
StrongLoop Overview
 
KrakenJS
KrakenJSKrakenJS
KrakenJS
 
The magic behind your Lyft ride prices: A case study on machine learning and ...
The magic behind your Lyft ride prices: A case study on machine learning and ...The magic behind your Lyft ride prices: A case study on machine learning and ...
The magic behind your Lyft ride prices: A case study on machine learning and ...
 
Non-blocking I/O, Event loops and node.js
Non-blocking I/O, Event loops and node.jsNon-blocking I/O, Event loops and node.js
Non-blocking I/O, Event loops and node.js
 
Catan world and Churchill
Catan world and ChurchillCatan world and Churchill
Catan world and Churchill
 
Going Live! with Comet
Going Live! with CometGoing Live! with Comet
Going Live! with Comet
 
Introduction to WAMP, a protocol enabling PUB/SUB and RPC over Websocket
Introduction to WAMP, a protocol enabling PUB/SUB and RPC over WebsocketIntroduction to WAMP, a protocol enabling PUB/SUB and RPC over Websocket
Introduction to WAMP, a protocol enabling PUB/SUB and RPC over Websocket
 
soft-shake.ch - Hands on Node.js
soft-shake.ch - Hands on Node.jssoft-shake.ch - Hands on Node.js
soft-shake.ch - Hands on Node.js
 
Game server development in node.js in jsconf eu
Game server development in node.js in jsconf euGame server development in node.js in jsconf eu
Game server development in node.js in jsconf eu
 
Rich User Interaction with SVG
Rich User Interaction with SVGRich User Interaction with SVG
Rich User Interaction with SVG
 
112 portfpres.pdf
112 portfpres.pdf112 portfpres.pdf
112 portfpres.pdf
 
TestUpload
TestUploadTestUpload
TestUpload
 
INAC Online Hazards Database App
INAC Online Hazards Database AppINAC Online Hazards Database App
INAC Online Hazards Database App
 

Kürzlich hochgeladen

Quick Doctor In Kuwait +2773`7758`557 Kuwait Doha Qatar Dubai Abu Dhabi Sharj...
Quick Doctor In Kuwait +2773`7758`557 Kuwait Doha Qatar Dubai Abu Dhabi Sharj...Quick Doctor In Kuwait +2773`7758`557 Kuwait Doha Qatar Dubai Abu Dhabi Sharj...
Quick Doctor In Kuwait +2773`7758`557 Kuwait Doha Qatar Dubai Abu Dhabi Sharj...
daisycvs
 
Jual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan Cytotec
Jual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan CytotecJual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan Cytotec
Jual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan Cytotec
ZurliaSoop
 
Challenges and Opportunities: A Qualitative Study on Tax Compliance in Pakistan
Challenges and Opportunities: A Qualitative Study on Tax Compliance in PakistanChallenges and Opportunities: A Qualitative Study on Tax Compliance in Pakistan
Challenges and Opportunities: A Qualitative Study on Tax Compliance in Pakistan
vineshkumarsajnani12
 

Kürzlich hochgeladen (20)

Quick Doctor In Kuwait +2773`7758`557 Kuwait Doha Qatar Dubai Abu Dhabi Sharj...
Quick Doctor In Kuwait +2773`7758`557 Kuwait Doha Qatar Dubai Abu Dhabi Sharj...Quick Doctor In Kuwait +2773`7758`557 Kuwait Doha Qatar Dubai Abu Dhabi Sharj...
Quick Doctor In Kuwait +2773`7758`557 Kuwait Doha Qatar Dubai Abu Dhabi Sharj...
 
Falcon Invoice Discounting: The best investment platform in india for investors
Falcon Invoice Discounting: The best investment platform in india for investorsFalcon Invoice Discounting: The best investment platform in india for investors
Falcon Invoice Discounting: The best investment platform in india for investors
 
KALYANI 💋 Call Girl 9827461493 Call Girls in Escort service book now
KALYANI 💋 Call Girl 9827461493 Call Girls in  Escort service book nowKALYANI 💋 Call Girl 9827461493 Call Girls in  Escort service book now
KALYANI 💋 Call Girl 9827461493 Call Girls in Escort service book now
 
Berhampur 70918*19311 CALL GIRLS IN ESCORT SERVICE WE ARE PROVIDING
Berhampur 70918*19311 CALL GIRLS IN ESCORT SERVICE WE ARE PROVIDINGBerhampur 70918*19311 CALL GIRLS IN ESCORT SERVICE WE ARE PROVIDING
Berhampur 70918*19311 CALL GIRLS IN ESCORT SERVICE WE ARE PROVIDING
 
Ooty Call Gril 80022//12248 Only For Sex And High Profile Best Gril Sex Avail...
Ooty Call Gril 80022//12248 Only For Sex And High Profile Best Gril Sex Avail...Ooty Call Gril 80022//12248 Only For Sex And High Profile Best Gril Sex Avail...
Ooty Call Gril 80022//12248 Only For Sex And High Profile Best Gril Sex Avail...
 
Falcon Invoice Discounting: Empowering Your Business Growth
Falcon Invoice Discounting: Empowering Your Business GrowthFalcon Invoice Discounting: Empowering Your Business Growth
Falcon Invoice Discounting: Empowering Your Business Growth
 
Buy gmail accounts.pdf buy Old Gmail Accounts
Buy gmail accounts.pdf buy Old Gmail AccountsBuy gmail accounts.pdf buy Old Gmail Accounts
Buy gmail accounts.pdf buy Old Gmail Accounts
 
Falcon Invoice Discounting: Unlock Your Business Potential
Falcon Invoice Discounting: Unlock Your Business PotentialFalcon Invoice Discounting: Unlock Your Business Potential
Falcon Invoice Discounting: Unlock Your Business Potential
 
Nashik Call Girl Just Call 7091819311 Top Class Call Girl Service Available
Nashik Call Girl Just Call 7091819311 Top Class Call Girl Service AvailableNashik Call Girl Just Call 7091819311 Top Class Call Girl Service Available
Nashik Call Girl Just Call 7091819311 Top Class Call Girl Service Available
 
Only Cash On Delivery Call Girls In Sikandarpur Gurgaon ❤️8448577510 ⊹Escorts...
Only Cash On Delivery Call Girls In Sikandarpur Gurgaon ❤️8448577510 ⊹Escorts...Only Cash On Delivery Call Girls In Sikandarpur Gurgaon ❤️8448577510 ⊹Escorts...
Only Cash On Delivery Call Girls In Sikandarpur Gurgaon ❤️8448577510 ⊹Escorts...
 
Uneak White's Personal Brand Exploration Presentation
Uneak White's Personal Brand Exploration PresentationUneak White's Personal Brand Exploration Presentation
Uneak White's Personal Brand Exploration Presentation
 
Unveiling Falcon Invoice Discounting: Leading the Way as India's Premier Bill...
Unveiling Falcon Invoice Discounting: Leading the Way as India's Premier Bill...Unveiling Falcon Invoice Discounting: Leading the Way as India's Premier Bill...
Unveiling Falcon Invoice Discounting: Leading the Way as India's Premier Bill...
 
Lundin Gold - Q1 2024 Conference Call Presentation (Revised)
Lundin Gold - Q1 2024 Conference Call Presentation (Revised)Lundin Gold - Q1 2024 Conference Call Presentation (Revised)
Lundin Gold - Q1 2024 Conference Call Presentation (Revised)
 
Jual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan Cytotec
Jual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan CytotecJual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan Cytotec
Jual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan Cytotec
 
Challenges and Opportunities: A Qualitative Study on Tax Compliance in Pakistan
Challenges and Opportunities: A Qualitative Study on Tax Compliance in PakistanChallenges and Opportunities: A Qualitative Study on Tax Compliance in Pakistan
Challenges and Opportunities: A Qualitative Study on Tax Compliance in Pakistan
 
Berhampur Call Girl Just Call 8084732287 Top Class Call Girl Service Available
Berhampur Call Girl Just Call 8084732287 Top Class Call Girl Service AvailableBerhampur Call Girl Just Call 8084732287 Top Class Call Girl Service Available
Berhampur Call Girl Just Call 8084732287 Top Class Call Girl Service Available
 
WheelTug Short Pitch Deck 2024 | Byond Insights
WheelTug Short Pitch Deck 2024 | Byond InsightsWheelTug Short Pitch Deck 2024 | Byond Insights
WheelTug Short Pitch Deck 2024 | Byond Insights
 
Phases of Negotiation .pptx
 Phases of Negotiation .pptx Phases of Negotiation .pptx
Phases of Negotiation .pptx
 
KOTA 💋 Call Girl 9827461493 Call Girls in Escort service book now
KOTA 💋 Call Girl 9827461493 Call Girls in  Escort service book nowKOTA 💋 Call Girl 9827461493 Call Girls in  Escort service book now
KOTA 💋 Call Girl 9827461493 Call Girls in Escort service book now
 
QSM Chap 10 Service Culture in Tourism and Hospitality Industry.pptx
QSM Chap 10 Service Culture in Tourism and Hospitality Industry.pptxQSM Chap 10 Service Culture in Tourism and Hospitality Industry.pptx
QSM Chap 10 Service Culture in Tourism and Hospitality Industry.pptx
 

WebGL visualization of a shipping terminal

  • 1. 3D MARINE PORT VISUALIZATION
  • 2. A LITTLE HISTORY  ECMAScript aka JavaScript  Created in mid-90s at Netscape  Called JavaScript as part of a marketing deal with Sun.  Standardized by ECMA.  Version 6 & 7 are in progress
  • 3. JAVA VS. JAVASCRIPT  Similarity: a C style syntax  OO Model  JavaScript is prototype-based  Java is class-based  Threads?  Java, yup  JavaScript has HTML5 Web Worker  Appeal  Java looks nice at first, later gets annoying  JavaScript seems horrible at first, gradually grows on you
  • 4. THE IDEA  Visualize a port terminal with a ubiquitous UI technology  Provide some level of user interaction  Create platform to explore additional features  Concerns?  Render Loop (FPS)  UI Interaction  Network Communication  Polygon Count  Scene Size
  • 5. THE DESIGN  Leverage THREE.js for 3D Library  Resources  3D Models  Textures  CSS  HTML  JavaScript  Etc.  CHE Objects  Forklifts  Cranes  Trucks  Rail  Ships
  • 6. TRUCK OBJECT  Port.Che.Truck  Properties:  _location  _speed  _movementVector  _distanceTraveled  Methods:  initRoute()  setVector()  makeVisible()  resetLocation() I’m a truck!  Create & extends Object4D “Object”
  • 7. MODELS & MOVEMENT RTG Movement Constraints
  • 8. OBJECT BREAKDOWN Actions - Port.Listeners - Port.Actions.Quays - Port.Actions.Rtgs - Port.Actions.Stackers - Port.Actions.Triggers - Port.Actions.Trucks App - Port.Cameras - Port.Yard.Gui - Port.Yard.Scene Gear - Port.Che.Block - Port.Che.Quay - Port.Che.Rtg - Port.Che.Ship - Port.Che.Stacker - Port.Che.Truck Management - Port.Manager - Port.Manager.Blocks - Port.Manager.Quays - Port.Manager.Rtgs - Port.Manager.Ships - Port.Manager.Stacker - Port.Manager.Trucks Core - Port.Core.Object4D - Port.Core.Container - Port.Util - Port.Geometry - Port.Maths - Port.Preloader - Port.Manager.Clock 3rd Party Libraries - Dat.GUI - jQuery - MouseTrap - OBJMTLLoader - TrackballControl - THREE - Kinetic
  • 9. INITIALIZATION & THE UI FREEZE Initialization Terminatio n Process Input Simulat e Render animation loop 1. Load geometry (Web Worker) 2. Load yard blocks (Local Storage) 3. Server-Sent Events 4. Initialize user controls 5. Create support geometry 6. Add lights and cameras 7. Initialize Scene 8. The Animation Loop!
  • 10. THE ANIMATION LOOP  requestAnimFrame API  Provides timer loop to animate. FPS Formula: 1000/(16 + N) fps  N = callback time in ms  Callback = 1 ms FPS is ~60fps  Callback = 84 ms FPS is ~10 fps  Higher FPS is better Initialization Terminatio n Process Input Simulat e Render animation loop
  • 11. RENDER CALLBACK  Scene Setup: Textures, 4 blocks, 4 trucks, 4 RTGs Render Time: 1 ms FPS: 60 FPS Initialization Shut down Process Input Simulat e Render animation loop
  • 12. 60 FPS – 4 Blocks – Render Time < 1ms
  • 13. RENDER CALLBACK  Scene Setup: Flat shaded, 100 blocks Render Time: 110 ms FPS: 8 FPS Initialization Shut down Process Input Simulat e Render animation loop
  • 14. 8 FPS – 100 Blocks – Render Time 110ms
  • 15. BIG PROBLEM – VARIABLE FPS  More polygons within frustum means slower rendering.  Moving frustum results in a variable frame rate  Require another level of time/movement dilation to smoothly translate models within the scene
  • 17. VARIABLE FPS Model Manager Clock Δ Quay Crane Manager RTG Manager Stacker Manager Truck Manager Ship Manager Management 1) Check CHE Status - Moving? - Stopped? - Waiting? 2) Assign Vector 3) Translate based upon clock Δ and CHE speed

Hinweis der Redaktion

  1. Good afternoon everyone. My name is Joshua Staples and I work in the R&amp;D group of Port a software company here in Oakland. Port provides a software product for shipping terminals around the world. It is considered by many to be the Microsoft of the shipping software industry
  2. Called Mocha &amp; LiveScript before JavaScript at NetscapeMicrosoft called it Jscript (andfixed Y2K issues in JavaScripts Date class).ECMA used to stand for European Computer Manufacturers Association. Kinda like Kentucky Fried Chicken is now called KFC.
  3. Prototypal Inheritance Prototypes are flexible. Mutable so you can give them new abilities. Lots of utilities do this. In a prototype system, objects inherit from objects. I think its more expressive and can offer more firepower.Classical Inheritance Classes are immutable. You can&apos;t modify or add new methods to them at runtime. Classes may or may not support multiple inheritance. It&apos;s verbose and complicated. You have abstract classes, final classes, interfaces, etc.HTML5 Web Worker operates in its own SandBoxDev Tools Example:Array.prototype.uniq = function () { console.log(&apos;new method!&apos;); }var x = [];x.uniq();
  4. Portand Oracle designed a joint 3D demo using JavaFX. Chose to pursue HTML5 because of device ubiquity.Port is the Microsoft of the shipping and rail terminal of the world.
  5. No real easing functions.Could result in some overshoot of distance in very low frame rate.Extends Object4D class (name play on THREE.js’ Object3D class).Object4D class has basic methods and properties needed to move an object in a variable FPS environment.
  6. For CHE that has hierachical movement (e.g. a RTG or Rubber-Tired Gantry crane), movement is constrained by work orders.Translate gantry crane to correct bay.After 1 has finished, move cab over particular tierLower crane and snag container from particular row.
  7. Yard block calculation works in local storage.Server-sent events are initialized and connected with managers for each CHE type.
  8. Think of this as an animation metronome.