Introduction to VRML By Salman Yussof Diego Iglesias.

Slides:



Advertisements
Similar presentations
1GR2-00 GR2 Advanced Computer Graphics AGR Lecture 10 VRML - An Introduction.
Advertisements

1GR2-00 GR2 Advanced Computer Graphics AGR Lecture 11 VRML Animation and Interaction.
17.1 Si23_03 SI23 Introduction to Computer Graphics Lecture 17 – VRML: A Rough Guide.
11.1 si31_2001 SI31 Advanced Computer Graphics AGR Lecture 11 VRML - An Introduction.
3D sprog X3D: Et 3D sprog til at definere realtime 3D grafik der kan formidles via WWW. – XML integreret – Baseret på VRML – Relativt nyt så der findes.
© TMC Computer School HC20203 VRML HIGHER DIPLOMA IN COMPUTING Chapter 1 – Introduction to VRML.
X3D Introduction to Web3D technology Enkhbold N. Information Communication University.
Welcome to 3D §The 3D graphics pipeline §Rigid-body transform §Homogeneous coordinates §Viewing transformation §Projection §Illumination.
B.Sc. Multimedia ComputingMedia Technologies 3D Technologies for the Web.
Event Routing §Some VRML nodes generate events in response to environmental changes or user interaction. Event routing gives authors a mechanism, separate.
© Richard Jones, 2009 CO641 Computer Graphics 1 CO641 Computer Graphics and Animation X3d / VRML Richard Jones SW107
Adding Functionality To Web-Based VR Basic Concepts Client – server model Client-side static Client-side scripting Server-side scripting.
What Is VRML? VRML is: Stands for Virtual Reality Modeling Language A simple text language for describing 3-D shapes and interactive environments VRML.
Virtual reality interfaces in connection with building process simulations. Prof. Nash Dawood Centre for Construction Innovation Research University of.
Multimedia and the WWW Howell Istance and Chris Hand, Napier University.
Cone Trees and Collapsible Cylindrical Trees
An Overview of VRML §Scene Graph Structure VRML files describe 3D objects and worlds using a hierarchical scene graph. Entities in the scene graph are.
© De Montfort University, D Graphics and VRML Howell Istance and Chris Hand* De Montfort University * now at
Java 3D Pablo Figueroa University of Alberta April 2000.
Cse591 Spring 981 VRML Basics The basic elements of VRML files are nodes. Every type of node has a set of fields associated with it. –Common single-valued.
Event Routing §Some VRML nodes generate events in response to environmental changes or user interaction. Event routing gives authors a mechanism, separate.
University College Dublin1 Scope ROOT Light SourceTransform Light SourceSphere.
Multimedia Web Components VRML. Introduction to VRML Case sensitive Most easy technique to provide interactive 3D environment in Web Required special.
CSC 890 Advanced Computer Graphics (Web3D System Design and Development) Ilmi Yoon Monday 4:10 - 6:45.
3D on-line representations Jan Valcik → introduction, main idea → VRML 97 → building of virtual worlds → VRML 97 at work → X3D → MUDVR → animations, navigation.
VRML Virtual Reality Modeling Language. What Are We Going to See? What is VRML? Syntax of the language Features Examples.
Scenes, Cameras & Lighting. Outline  Constructing a scene  Using hierarchy  Camera models  Light models.
Lahti International Week 2006 Introduction to X3D Lesson 2: Animating your models.
1 Chapter 20 — Creating Web Projects Microsoft Visual Basic.NET, Introduction to Programming.
1 Perception, Illusion and VR HNRS 299, Spring 2008 Lecture 19 Other Graphics Considerations Review.
Creative Commons Attribution 3.0 creativecommons.org/licenses/by/3.0 Key Abstractions in Game Maker Foundations of Interactive Game Design Prof. Jim Whitehead.
© TMC Computer School HC20203 VRML HIGHER DIPLOMA IN COMPUTING Chapter 3 – Object Definition in VRML.
Virtual reality. Tasks 3D digital model from planes 3D digital model of existing objects Office work Field observations Solid modeling Photogrammetry.
VRML Dr. Alun Moon What is VRML The Virtual Reality Modeling Language (VRML) is a file format for describing interactive 3D objects.
Shapes Properties Binding Chung Ji Hye.
CS324e - Elements of Graphics and Visualization Checkerboard World.
VRML - 1 Virtual Reality Modeling Language (VRML) Peter O’Grady.
Graphical Objects and Scene Graphs 1 Angel: Interactive Computer Graphics 5E © Addison-Wesley 2009.
VRML Scene Graphs. Learning Objectives Understand the concept of a scene graph Understand how VRML defines transformations (translations, rotations, and.
History of VRML and Its Development Process. Learning Objectives Understand the history of VRML Understand the purpose and functions of VRML Learn how.
1 Virtual Reality Modeling Language (VRML97) ©Anthony Steed
Open Inventor A short introduction. Capabilities of Open Inventor Easy construction of 3D scenes User interaction Animation.
CVVR National Dong Hwa Univ. 國立東華大學 VRML Virtual Reality Modeling Language
Computer Graphics Group Script node Jiří Žára. Computer Graphics Group Contents 1.Script node 2.Motion generators 2Script node.
H3D API Training Part 2.1: X3D. Outline  Scene graphs  X3D – XML syntax  X3D components overview.
VRML virtual reality modeling language. what is it? standardised (sort of) notation for virtual reality over the web text file (use normal text editor)
111/16/ :14 UML Instance Transformation x y z x y z x y z x y z SRT Model Coordinates.
Virtual Reality Modeling Language 97. What’s VRML? Virtual Reality Modeling Language 2D/3D graphics Audio:.wav,.mid Video: MPEG-1 Interactivity: time-
111/22/ :40 UML VRML 2.0 Scene Graph Structure Group Transformation Shape Nodes.
CS324e - Elements of Graphics and Visualization Java 3D Intro.
B.Sc. Digital Media3D Technologies for the Web 3D Technologies.
VRML Anthony Steed Department of Computer Science University College London ©Anthony Steed
Interface Opportunities for 3D Data and Media User Interface Software TechNote Panel Virginia Tech CS Fall 2002 Nicholas F. Polys Umur Yilmaz Will Lee.
© TMC Computer School HC20203 VRML HIGHER DIPLOMA IN COMPUTING Chapter 2 – Basic VRML.
Modeling, CG, and others Jyun-Ming Chen Fall 2001.
Intro to VRML Let’s build something! The source code examples in this tutorial WORK!
DESIGNING 3D WEB USING VRML Bob Hobbs Introduction to Virtual Reality and Simulation CE
Web3D Jyun-Ming Chen Fall Contents Definitions, components Examples Task breakdown Survey of available technologies Recommended platform Details.
1 9 Lighting a Scene v There are four types of lighting: –ambient light –directional light –point light –spotlight v Any number of these can be added to.
© TMC Computer School HC20203 VRML HIGHER DIPLOMA IN COMPUTING Chapter 6 – Texture Maps.
VIRTUAL REALITY (VR) INTRODUCTION AND BASIC APPLICATIONS الواقع الافتراضي : مقدمة وتطبيقات Dr. Naji Shukri Alzaza Assist. Prof. of Mobile technology Dean.
© TMC Computer School HC20203 VRML HIGHER DIPLOMA IN COMPUTING Chapter 5 – Animation in VRML.
© TMC Computer School HC20203 VRML HIGHER DIPLOMA IN COMPUTING Chapter 4 – Object Manipulation in VRML.
Institute for Computer Graphics and Vision Computer Graphics and Interactive Systems 1 Grabner HS i4, 2006/03/08 Web3D, VRVU, SGP Web3D ( ) VRVU.
DLP for Virtual Environments (I)
X3DOM : Integrating 3D content seamlessly into webpage
MPEG-4 Binary Information for Scenes (BIFS)
Department of Computer Science University College London
VIRTUAL REALITY IN ROBOTICS
Lecture 3. Virtual Worlds : Representation,Creation and Simulation
Presentation transcript:

Introduction to VRML By Salman Yussof Diego Iglesias

What is VRML? VRML stands for Virtual Reality Modelling Language and is pronounced ‘vermil’. VRML stands for Virtual Reality Modelling Language and is pronounced ‘vermil’. n It is a standard for delivering 3D rendering on the net, just like HTML is a standard for web pages. n VRML is a subset of the Open Inventor standard developed by SGI for their graphics workstation.

The ‘World’ representation n VRML includes many of the things that go into making a world. It has a way of describing geometry which creates objects and spaces in which you can move around, as well as light, texture and sound which can be approached and viewed from whatever angle. n It is from this ‘worldly’ imitation that VRML files get their name. The files are called ‘worlds’ and have ‘.wrl’ extension.

VRML 1.0 n This is the first generation of VRML. n It describes the foundations of a world including geometry, lighting, color, texture and linking. n VRML 1.0 is designed to meet the following requirements: –Platform independence –Extensibility –Ability to work well over low-bandwidth connections n No support for interactive behaviors

VRML 2.0 n This is the current generation of VRML. n It has a richer level for interactivity and includes support for animation, spatial sound and scripting in addition to features that are already supported in VRML 1.0. n VRML Architecture Board made it official in March 1996

VRML97 n VRML 97 is the ISO standard for VRML n It is developed based on VRML 2.0

Features in VRML97 More realism in static worlds n Sound objects with controllable attenuation n An efficient system to describe irregular ground terrains n Extrusion objects for advanced but compact modelling n A more powerful background coloring and panorama system n A fog system allowing underwater and cloudy environments to be represented n The ability to use MPEG video as a texture map

Features in VRML97 Interaction from sensors: n Collision detection gives the user a sense of substance as they move in the world n Touch sensors allow reactions to a users deliberate actions n Proximity sensors allow reactions to a user’s not so deliberate actions n Visibility sensors allow conservation of resources

Features in VRML97 Motion, behaviors and beyond: n Interpolators provide engines to implement animation of any sort. n Scripting in JavaScript or Java allows everything from simple logic devices to fully blown analytical engines providing a wealth of complexity. n Prototypes extend the existing variety of object types with efficient reuse and simple scene graph structure. n A navigation information object provides the browser software with details of the speed and nature of the users movements in the world.

Writing VRML descriptions n VRML code is simply a text file, case sensitive n Header: –#VRML V2.0 utf8 n Comments indicated by ‘#’ sign n Terminology: –Nodes: a world is made up of nodes which are types of objects –Fields: describe properties of a node

Example #VRML V2.0 utf8 WorldInfo { title "Example 1" } DEF FBOX Shape { appearance Appearance { material Material { diffuseColor } geometry Box { } Node Field (uses default values)

Shapes n Box –geometry Box {size } n Cylinder –geometry Cylinder {radius 0.5 height 10 top FALSE} n Cone –geometry Cone {bottomRadius 5 height 10 side TRUE bottom FALSE} n Sphere –geometry Sphere { radius 10,000,000} n Text & FontStyle

Materials n Material Node properties: –diffuseColor: The normal color of the object –specularColor: The color of highlights on shiny objects –emissiveColor: The object 'glows' with a light of it's own of this color. It doesn't cast light on any other objects though –ambientIntensity: The amount of ambient light that the object reflects –shininess: How reflective the object is –transparency: How transparent the object is. Note, some browsers will not support partly-transparent objects.

Transformations n Distances measured in meters (convention) n Angles measured in radians n Transformation types: –Translation, Rotation, and Scaling n Applied in following order (use nesting for custom) –Scale, then Rotate, the Translate n Example: Transform { translation rotation scale children [ USE FBOX ]

Example 1 #VRML V2.0 utf8 Transform { children [ children [ NavigationInfo { headlight FALSE } # We'll add our own light NavigationInfo { headlight FALSE } # We'll add our own light DirectionalLight { # First child DirectionalLight { # First child direction # Light illuminating the scene direction # Light illuminating the scene } Transform { # Second child - a red sphere Transform { # Second child - a red sphere translation translation children [ children [ Shape { Shape { geometry Sphere { radius 2.3 } geometry Sphere { radius 2.3 } appearance Appearance { appearance Appearance { material Material { diffuseColor } # Red material Material { diffuseColor } # Red } } ] } ( … )

Example 2 #VRML V2.0 utf8 Transform { children [ children [ DEF Joe Shape { geometry Sphere {} } DEF Joe Shape { geometry Sphere {} } Transform { Transform { translation translation children DEF Joe Shape { geometry Sphere { radius.2 } } children DEF Joe Shape { geometry Sphere { radius.2 } } } Transform { Transform { translation translation children USE Joe children USE Joe } ]}

Example 3 #VRML V2.0 utf8 PROTO TwoColorTable [ field SFColor legColor field SFColor topColor ] { Transform { children [ Transform { # table top translation children Shape { appearance Appearance { material Material { diffuseColor IS topColor } } geometry Box { size } } Transform { # first table leg translation children DEF Leg Shape { appearance Appearance { material Material { diffuseColor IS legColor } } geometry Cylinder { height 1 radius.1 } } Transform { # another table leg translation children USE Leg } Transform { # another table leg translation children USE Leg } Transform { # another table leg translation children USE Leg } ] # End of root Transform's children } # End of root Transform } # End of prototype # The prototype is now defined. Although it contains a # number of nodes, only the legColor and topColor fields # are public. Instead of using the default legColor and # topColor, this instance of the table has red legs and # a green top: TwoColorTable { legColor topColor } NavigationInfo { type "EXAMINE" } # Use the Examine viewer

Example 4 Example 4 #VRML V2.0 utf8 DEF OpenVault Script { # Declarations of what's in this Script node: eventIn SFTime openVault eventIn SFBool combinationEntered eventOut SFTime vaultUnlocked field SFBool unlocked FALSE # Implementation of the logic: url "javascript: function combinationEntered(value) { unlocked = value; } function openVault(value) { if (unlocked) vaultUnlocked = value; }" } Shape { appearance Appearance { material Material { diffuseColor } } geometry Sphere { } } Sound { source DEF Click AudioClip { url "click.wav" stopTime 1 } minFront 1000 maxFront 1000 minBack 1000 maxBack 1000 } DEF TS TouchSensor { } ROUTE TS.isOver TO OpenVault.combinationEntered ROUTE TS.touchTime TO OpenVault.openVault ROUTE OpenVault.vaultUnlocked TO Click.startTime

Additional Examples n Interpolation Interpolation n Interaction Interaction n Tour Tour n Distance Sensor Distance Sensor Distance Sensor n Graphics (1) Graphics (1) Graphics (1) n Graphics (2) Graphics (2) Graphics (2) n Graphics (3) Graphics (3) Graphics (3)

Acknowledgements n Example VRML code from – – es.html

References n VRML Consortium/Web3D – n VRML repository: – n VRML 1.0 Specification – n VRML 2.0 Specification – n VRML97 Specification –

Examples n VRML97 Examples – es.html n 3D Web Graphics Using VRML Book Examples – n Links to good examples: –

Tutorials n VRML97 Tutorial – n VRML Works Tutorial – html n Cosmo VRML Tutorial – n VRML Repository Tutorial links – bin/display.cgi?category=Tutorials+-+VRML

Questions (and Answers) n Q: How to define the trajectory of the walk-through example? n A: There are two ways in which to implement the tour: –Using javascript to control the viewer’s camera position –Using VRML sensors, in particular the time sensor n The Tour example was implemented using the time sensor approach –An array of tour positions is defined together with a way to interpolate between them –A touch sensor determines when the timer is started –Each tick of the timer is routed to the position interpolator which sets a new orientation and translation

Tour Example DEF GuidePI PositionInterpolator { key [ 0, 0.2, 0.3, 0.5, 0.6, 0.8, 0.9, 1 ] keyValue [ 0 0 0, , , , , , ] } n Relevant source code DEF GuideRI OrientationInterpolator { key [ 0, 0.2, 0.3, 0.5, 0.6, 0.8, 0.9, 1 ] keyValue [ , , , , , , , , ] } DEF TS TimeSensor { cycleInterval 30 } # 30 second tour ROUTE StartTour.touchTime TO TS.startTime ROUTE TS.fraction_changed TO GuidePI.set_fraction ROUTE TS.fraction_changed TO GuideRI.set_fraction ROUTE GuidePI.value_changed TO GuideTransform.set_translation ROUTE GuideRI.value_changed TO GuideTransform.set_rotation