114
Sébastien ‘Cb’ Kuntz @Cb_VRGeek Philosophy and architecture SEARIS 2014

IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Embed Size (px)

DESCRIPTION

MiddleVR is a generic VR plugin. SEARIS is the "Software engineering and architecture for realtime interactive systems" workshop for IEEEVR.

Citation preview

Page 1: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Sébastien ‘Cb’ Kuntz @Cb_VRGeek

Philosophy and architectureSEARIS 2014

Page 2: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 3: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Plan

• Introduction

• Origin of MiddleVR

• Goals

• Demo

• Philosophy & Architecture

• Conclusion

Page 4: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

(French railways)

“Creating Virtual Reality Games:

The Fundamentals”

Founder & President

Sébastien ‘Cb’ Kuntz

Page 5: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 6: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Zone hunter (Virtuality-1994)

Page 7: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

FRENCH RAILWAYS - SNCF

• Polhemus magnetic tracker, treadmill, 5DT Glove• C++ / OpenSceneGraph / VRPN / OpenAL

Page 8: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

FRENCH RAILWAYS - SNCF

Page 9: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

VIRTOOLS

Page 10: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

VIRTOOLS VR PACK

Page 11: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 12: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

• VR tools to simplify VR

Page 13: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Virtual reality

Presence in a virtual world

Page 14: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

RidiculousIf it’s real VR, you probably

look ridiculous !

Page 15: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

• Build hardware

To create and maintain presence,you need to ...

• Build software

• Build user experience

Page 16: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

The challenges of creating a VR software

Page 17: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

“VR is mainly a software problem”

Jaron Lanier

Page 18: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Device management

Physical devicePhysical device DriverDriver ApplicationApplication

Page 19: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Device management

Tracker 1Tracker 1Driver Tracker Driver Tracker

11

ApplicationApplication

Tracker 2Tracker 2 Driver Driver Tracker 2Tracker 2

Page 20: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 21: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 22: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 23: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Correct perspective

(c) Johnny Lee

Page 24: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Correct perspective

Page 25: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Stereoscopy

Page 26: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Warping & Blending

Page 27: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Warping & Blending

Page 28: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Graphics cards limitations

• Number of outputs

• Processing power

Page 29: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

multiple graphics cards

• Pro

• More outputs

• More processing power

• Con

• 3D engines are not optimized for multi-pipe

Page 30: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Cluster

• Pro

• More outputs

• More processing power

• Con

• 3D engines don’t support clustering

Page 31: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

• No seams across displays require 3 layers of sync

• 3D objects synchro (Scenelock)

• New images display (Swaplock)

• Left/Right eyes (Genlock)

Cluster

Page 32: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Interactions

• Many different 3D user interactions

• Navigation

• Selection

• Manipulation

• Draw

• System control

• etc.

Page 33: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Interactions are dependent on hardware

Page 34: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Menus

Page 35: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Haptics(force feedback)

Page 36: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Deployment

• Modify application to

• Change drivers

• Change displays

• Change interactions

Page 37: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 38: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

• Platform for creating interactive 3d applications

• Widely used

• 2.5 million registered developers

Page 39: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

• High-quality rendering

• Deferred renderer

• Occlusion culling

• Realtime shadows

• Ambient occlusion

• Light mapping

Page 40: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 41: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Unity 3D Features• Programming

• C#, Javascript

• Profiler

• Physics

• NVidia PhysX

• Cloth

• Soft/rigid bodies

• Ragdolls

• Cars

3D formats

FBX, Collada, 3DS, OBJ…

Audio engine

Networking

Terrain

Page 42: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Editor

• Simple to use

• Create your own tools inside Unity

Page 43: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Asset store

• Buy / sell assets

• 3D models

• Textures

• Shaders

• Scripts

• Editor plugins

Page 44: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

DesktopDesktop

Page 45: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

• Build hardware

To create and maintain presence,you, the author, need to ...

• Build software

• Build user experience

Page 46: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 47: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 48: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Existing VR software

• VRPN

• OpenTracker

• VRJuggler

• Virtools

• Worldviz

• …

Page 49: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

VRPN

Page 50: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

VR Juggler

Page 51: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

VIRTOOLS VR PACK

Page 52: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Worldviz Vizard

• Based on OpenSceneGraph

• Python

Page 53: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Worldviz Vizard

Page 54: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

The need for betterVR software tools

• Hardware getting cheaper

• But engineers are not getting cheaper

• Need to be more efficient and spend less time creating apps

• Democratization

• VR developers are not all engineers anymore

Page 55: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Goals

• Simplify VR

• Simplify creation of VR applications

• Simplify deployment of VR applications

• Create new VR tools

• Adapting existing 3D applications

Page 56: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

What is ?

• Generic VR plugin (C++ SDK)

• Functionalities○Manage input devices

•3D trackers, keyboard, mouse, joystick○Manage display

•Viewports, cameras, stereoscopy, cluster○High-level building-blocks

○Interactions○Menu

Page 57: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Architecture

MiddleVR (C++)MiddleVR (C++)

DriversDrivers OpenGLOpenGL DirectDirectXX

NetworNetworkk

C# WrapperC# Wrapper

GUIGUI UnityUnity

Lua Lua WrapperWrapper

Lua Lua WrapperWrapper

Python Python WrapperWrapperPython Python

WrapperWrapper

Page 58: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 59: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 60: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 61: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 62: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

MiddleVR Features

Page 63: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Supported Devices• Via VRPN :

• A.R.T• Vicon• Optitrack• Wiimote

• Polhemus Fastrak Tracker, 3Space Tracker, Patriot Trackers,

• Ascension Flock of Bird

• Intersense IS600, IS900

• 3dTech HiBall-3000 Wide Area Tracker,

• Advanced Realtime Tracking Gmbh DTrack Client,

• World Viz Precision Position Tracker PPT 1.2,

• Natural Point Optitrack Rigid Body Toolkit,

• Phasespace optical tracking OWL,

• ...

• Native drivers• Oculus Rift• Leap Motion• Kinect (Microsoft SDK)• PNI SpacePoint Fusion• GameTrak• Razer Hydra• SpaceMouse• Motion Analysis (beta)

Page 64: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Haptics(force feedback)

Page 65: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

VR Camera• MiddleVR computes all the cameras’

parameters automatically

• Correct perspective

• Scale 1

Page 66: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Stereoscopy

• Active stereoscopy (OpenGL Quad-Buffer)

• Which Unity can’t natively handle

• Passive stereoscopy

Page 67: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Viewports management

Page 68: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Simply configure your system

Page 69: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Navigations

Page 70: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Homography

Page 71: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Cluster & Multi-pipe

• Scenelock

• Swaplock

• Genlock

• Multi-pipe (soon)

Page 72: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Supported displays

• Virtually any HMD• VR-Wall, Powerwall• Workbench, Holobench• HoloStage• CAVEs• 3D TVs• zSpace• Igloo Vision• …

Page 73: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Goals

• Simplify creation of VR applications

• Simplicity of adding VR into application

• Simplicity of API

• High-level tools

• Interactions: Selection, manipulation, navigation, menus, GUIs

Page 74: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Example of device management

Page 75: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Driver 1

Page 76: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Driver 2

Page 77: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Device management

Page 78: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 79: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

MiddleVR

Page 80: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Class reference

Page 81: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

The value of Simplicity

Page 82: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

The value of simplicity

“Perfection is achieved, not when there is nothing more to add, but

when there is nothing left to take away”

Antoine de St Exupery

Page 83: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

The value of simplicity

• For each feature you add

• Test

• Document

• Support / maintain

• Each feature costs !!

Page 84: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

The value of simplicity• Huge value in simplicity !

• User side

• Faster to learn, less to remember

• Developer side

• Faster to code

• Easier maintain

• Less bugs

• Business side

• Need less coders

• More interesting features

• Easy download / setup > Quickly validate on user’s hardware !

• Easier support

Page 85: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

API in simple english• Long discussions for naming of functions, classes, variables

• Consistent api

• SetNumButtons, SetButtonsNum, SetNbButtons > SetButtonsNb

• French not good at english

• Analog ? Digital ? Proxy ?

• Use natural terms depending on device

• Joystick->GetAxisValue()

• Joystick->IsButtonPressed()

• Keyboard->IsKeyPressed()

• Why “Register” ? Why not “Add” ?

• Why so complex, want to sound very clever ?

• AddDevice, AddCamera, …

• API in degrees, because more intuitive / simple to work with

Page 86: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Simplified API

• Simple but complete API

• Like legos

• Rotate

• Node3D->Rotate( Quat )

• Node3D->Rotate( Euler )

• Node3D->Rotate( Axis, Angle)

• Quat( quat ), Quat( Euler ), Quat( Axis, Angle)

Page 87: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

The value of simplicity

“Simplicity is the ultimate sophistication”

DaVinci

Page 88: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

The value of simplicity• Design user interface for the 80%

• Don’t ruin the experience for the 20%

• Simple things should be simple

• Complex things can be complex

• Put in an “advanced menu”

• Don’t let beauty of design ruin user experience

• Like real life architects who want their design to be beautiful but totally unusable on a day to day

• Example of Lego

• Simple but complete

Page 89: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Optimizations

• Engineers have a strong tendency to over-optimise

• Complexifies code

• Code must be above all readable

• To avoid bugs

• To maintain maintenability

• If you want to optimise

• First profile your code

• Optimize what is *really* taking time

• not what you *think* takes time

Page 90: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Empathy

“The ability to understand and share the feelings of another.”

Test with users

Page 91: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Hardware SDK are mostly too complicated

Page 92: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Drivers• Why not just a few simple functions with

sensible defaults ?

• Init()

• Update()

• GetValue()

• Destroy()

• And add more functions for more advanced

Page 93: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Documentation

• User Guide

• Class references

Page 94: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Goals

• Simplify deployment of VR applications

• GUI to configure VR systems

• Dynamic reconfiguration of application

• Ship with standard configurations

• Abstractions

Page 95: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Deployment

• Abstractions

• Devices

• 3D Nodes (User)

• Interactions (soon)

Page 96: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Device management

Driver Tracker Driver Tracker 11

ApplicationApplication

Driver Driver Tracker 2Tracker 2

Page 97: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Device abstraction

Virtual Virtual DeviceDevice

ApplicationApplication

Driver Tracker Driver Tracker 11

Driver Driver Tracker 2Tracker 2

Page 98: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Device management

DriverDriver

Virtual Virtual DeviceDevice

ApplicationApplication

SimulatioSimulationn

ReplayReplay

Page 99: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Display

• Cameras & viewport created dynamically

Page 100: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

User• Human-centric rather than techno-

centric

Page 101: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Virtual Device Virtual Device 11

HandHand(3D Node)(3D Node) ApplicationApplication

Virtual Device Virtual Device 22

Inverse Inverse KinematicsKinematics

User abstraction

Page 102: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Interactions• MiddleVR includes high-level

interactions

• Navigation

• Selection

• Manipulation

• … More to come

• Future: Interactions abstractions

• Dynamically change interactions based on hardware

Page 103: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Interactions abstraction?

Grab-airGrab-air

NavigationNavigation

ApplicationApplication

PointPoint

SteeringSteering

SelectionSelection

ManipulationManipulation

RaycastinRaycastingg

Go-goGo-go

HandHand

HomerHomer

HandHand

WIMWIM

Page 104: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

• How to create portable interactions ?

• Navigations can be portable

• Except collisions

• Generalise what is generalisable

• + Custom part for engine dependent

• Collisions

• Highlights

• Gizmos

Interactions

Page 105: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Menus• Ability to create menus and GUIs in HTML5

(soon)

Page 106: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture
Page 107: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Create immersive HTML5 GUI

Page 108: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

C++ Reflexion

• Also for configuration file

• Cluster synchronisation

• Accessing drivers specific information

Page 109: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Working with multiple 3D engines

• Different coordinate systems

• vrCoordinateSystem( Front, Up, Right )

• +/- X,Y,Z

• OpenGL:

• Front= -Z

• Up = +Y

• Right = +X

• DirectX:

• Front=+Z

• Up=+Y

• Right=+X

Page 110: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Working with multiple 3D engines

• C++

• Compiling

• STL, Boost

• Strings (Wide strings)

• Link issues

• Different compilers (VC2005/2008/2010/2012)

• Different languages

• C wrapper

• Lua wrapper

Page 111: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

• Simplicity• Creation• Deployment

•Adaptability•Hardware• Software

Page 112: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

Our future

• Games/apps development:

Page 113: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

ConclusionConclusion

Page 114: IEEE VR-SEARIS 2014 Keynote - MiddleVR - Philosophy and architecture

http://www.imin-vr.com/download

Thank you !Questions ?

[email protected]@Cb_VRGeek

@imin_vr