際際滷

際際滷Share a Scribd company logo
CS320n  Elements of Visual
Programming
Introduction to Alice
Mike Scott
(際際滷s 1-1)
Visual Programming Introduction to Alice 2
What We Will Do Today
 look at the Alice programming
environment
 create some simple programs in Alice
Visual Programming Introduction to Alice 3
What is Alice?
 Named in honor of Lewis Carrolls (pen
name) Alice in Wonderland
 Charles Lutwidge Dodgson was also a
mathematician and logician
 A modern programming tool
 purpose of tool, learn how to program, write
algorithms
 3-D graphics
 3-D models of objects
 Animation
 Objects can be made to move around virtual
world (a simulation or a video game. Simple
Pixar.)
Visual Programming Introduction to Alice 4
Computer Programs
 General purpose programming languages
can be used for almost any task
 Alice is not a general purpose
programming language.
 It is an application specific language
 designed for a specific task, creating 3D
animations
 lots of application specific languages.
Example: language for working with DNA data
Visual Programming Introduction to Alice 5
Fundamental Tools
 All languages contain these elements
1. list of instructions  Pack lunch, pack snack, put
homework in backpack.
2. decision making  If I didnt shave yesterday,
shave today.
3. repetition of behavior  Do a load of laundry until
there is no more dirty laundry.
4. modularization. Big rocks into little rocks. To do a
load of laundry: gather clothes, get clothes right-
side out, put clothes of similar color into washing
machine
5. Generalization: Solve many different problems with
one set of instructions
6. Compute a result  How much is it going to cost to
fill up my car with gas?
Visual Programming Introduction to Alice 6
What does Alice run on?
 Alice is free.
 Alice is written in Java
 only working versions are for PCs and Macs
with OSX 10.3 or higher (relatively new, may
still have bugs)
 Sorry, no Linux, yet
 the book comes with a copy of Alice for
Windows machines
 www.alice.org
 also on the computers in the CS Elements lab
Visual Programming Introduction to Alice 7
Fast Start Up
 Can quickly learn to create
 a simple animation in a matter of minutes
 a non-trivial animation in a few class periods
 Can learn to use the Alice interface in a
few class periods if you do a couple of
exercises at home
Visual Programming Introduction to Alice 8
Installing Alice
 If you want to install Alice on you computer at home
 use the CD that comes with the textbook
 CD installation is straightforward
 download Alice from the web
 http://www.alice.org/downloads/authoringtool/
 file format is .zip
 must unzip file using a program such as winzip
 problems? post to newsgroup
Visual Programming Introduction to Alice 9
Memory Management
 Alice automatically manages memory
 But, writing and testing an animation is an
intense load on the computing system
 a crash can occur.
 Best solution:
 Alice (the program) reminds you every so often
so save your work
 save your programs often!
 if working in lab when you logout the computer is
wiped -> save to your account or to a backup
system such as a memory stick
Visual Programming Introduction to Alice 10
The Power of Alice
 Automatically keeps track of 3-D objects
 what objects are in the virtual world
 types of objects
 positions of objects in the world
Visual Programming Introduction to Alice 11
Demo
 Starting Alice
 Loading a World
 Running A World
 Saving a World
 How to Exit
Visual Programming Introduction to Alice 12
The World
 Alice Programs / Movies take place in a
virtual world
 When you start a new world in Alice you
select the background
The world consists
of a sky and the ground
Cant be changed after
creating the world
the world is not infinite
DEMO
(I dont like roller
coasters any more)
Visual Programming Introduction to Alice 13
Objects in Alice
 Objects already exist. Hundreds of them
Visual Programming Introduction to Alice 14
Program an Object
Visual Programming Introduction to Alice 15
Where Do Objects Come From?
 They are pre built
 creating 3D objects is another area of computing and graphic
design
 Sources of 3D objects
 the local gallery that comes with the software
 Alice web gallery
 How are objects added to the world?
Visual Programming Introduction to Alice 16
Adding Objects
 Click on the green Add Objects button
 World expands and local gallery displayed
Visual Programming Introduction to Alice 17
Adding Objects
 Local gallery divided into a directory based
on subject
 add instances of objects to world by
 dragging and dropping or
 click on object and select add instance option
Visual Programming Introduction to Alice 18
Objects in the World
 Can have multiple instances of objects
from the same class in the World
 class: like a cookie cutter
 objects: like the cookies
star cookie cutter
star cookie class
star cookies
star cookie objects
Visual Programming Introduction to Alice 19
Objects in the World
penguin class penguin objects in a virtual world
Visual Programming Introduction to Alice 20
Objects in the World
 The Objects that are present in the current
world are listed in the Object Tree
 The top left panel in the Alice
programming environment
 Every world comes with a
light, a camera (point of
view for the movie when
played), and the ground
Visual Programming Introduction to Alice 21
Object Dimensions
 Objects in Alice worlds are 3 dimensional
height width depth
Visual Programming Introduction to Alice 22
Object Position
 Objects
 are positioned in 3-D space
 Have six degrees of freedom (directions of movement)
Visual Programming Introduction to Alice 23
Objects Know Relative Directions
 Yellow box around
penguin is its
bounding box
 light blue line is
up/down
 pink line is
left/right
 dark blue line is
forward backward
 DEMO
Visual Programming Introduction to Alice 24
Exercises
 if you want to work at home, install Alice on
your computer
 Complete Appendix A, Part 1, using Alice
 a walkthrough of using Alice
 Complete the tutorials that come with Alice
Visual Programming Introduction to Alice 25
Starting Tutorials

More Related Content

Viewers also liked (20)

Specification of a Visual Programming Language by Example
Specification of a Visual Programming Language by ExampleSpecification of a Visual Programming Language by Example
Specification of a Visual Programming Language by Example
Maximilian Fellner
Visual basics Express Project
Visual basics Express ProjectVisual basics Express Project
Visual basics Express Project
Iftikhar Ahmed
Visual basic 6Visual basic 6
Visual basic 6
Jenny Godoy Maldonado
Html tag
Html tagHtml tag
Html tag
NIRMAL FELIX
Visual basic 6.0Visual basic 6.0
Visual basic 6.0
maiker perez
Visual basic 6.0
Visual basic 6.0Visual basic 6.0
Visual basic 6.0
Aarti P
visual basic 6.0visual basic 6.0
visual basic 6.0
lesly53
Visual programming
Visual programmingVisual programming
Visual programming
Aswinraj Manickam
Visual BasicVisual Basic
Visual Basic
Victor Zapata
Human Ear
Human EarHuman Ear
Human Ear
Muhammad Bilal Tariq
Chapter 2
Chapter 2Chapter 2
Chapter 2
Muhammad Salman
Visual Basic 6.0
Visual Basic 6.0Visual Basic 6.0
Visual Basic 6.0
Palitha Baddegama
visual basic for the beginner
visual basic for the beginnervisual basic for the beginner
visual basic for the beginner
Salim M
Visual Basic Programming
Visual Basic ProgrammingVisual Basic Programming
Visual Basic Programming
Osama Yaseen
Osi model
Osi modelOsi model
Osi model
Priyanka Sharma
Chapter 1 Introduction to Visual Basic 2010 Programming
Chapter 1  Introduction to Visual Basic 2010 Programming Chapter 1  Introduction to Visual Basic 2010 Programming
Chapter 1 Introduction to Visual Basic 2010 Programming
francopw
Cryptography
CryptographyCryptography
Cryptography
Sidharth Mohapatra
Visual Basic Controls ppt
Visual Basic Controls pptVisual Basic Controls ppt
Visual Basic Controls ppt
Ranjuma Shubhangi
Osi model vs TCP/IP
Osi model vs TCP/IPOsi model vs TCP/IP
Osi model vs TCP/IP
Mannu Khani
Visual Basic 6.0
Visual Basic 6.0Visual Basic 6.0
Visual Basic 6.0
Anjan Mahanta
Specification of a Visual Programming Language by Example
Specification of a Visual Programming Language by ExampleSpecification of a Visual Programming Language by Example
Specification of a Visual Programming Language by Example
Maximilian Fellner
Visual basics Express Project
Visual basics Express ProjectVisual basics Express Project
Visual basics Express Project
Iftikhar Ahmed
Visual basic 6Visual basic 6
Visual basic 6
Jenny Godoy Maldonado
Visual basic 6.0Visual basic 6.0
Visual basic 6.0
maiker perez
Visual basic 6.0
Visual basic 6.0Visual basic 6.0
Visual basic 6.0
Aarti P
visual basic 6.0visual basic 6.0
visual basic 6.0
lesly53
Visual BasicVisual Basic
Visual Basic
Victor Zapata
visual basic for the beginner
visual basic for the beginnervisual basic for the beginner
visual basic for the beginner
Salim M
Visual Basic Programming
Visual Basic ProgrammingVisual Basic Programming
Visual Basic Programming
Osama Yaseen
Chapter 1 Introduction to Visual Basic 2010 Programming
Chapter 1  Introduction to Visual Basic 2010 Programming Chapter 1  Introduction to Visual Basic 2010 Programming
Chapter 1 Introduction to Visual Basic 2010 Programming
francopw
Visual Basic Controls ppt
Visual Basic Controls pptVisual Basic Controls ppt
Visual Basic Controls ppt
Ranjuma Shubhangi
Osi model vs TCP/IP
Osi model vs TCP/IPOsi model vs TCP/IP
Osi model vs TCP/IP
Mannu Khani

Similar to Visual programming (20)

Alice ppt ch01
Alice ppt ch01Alice ppt ch01
Alice ppt ch01
barkeshli
Ios-training-institute-in-mumbai
Ios-training-institute-in-mumbaiIos-training-institute-in-mumbai
Ios-training-institute-in-mumbai
vibrantuser
Deep Learning with Python (PyData Seattle 2015)
Deep Learning with Python (PyData Seattle 2015)Deep Learning with Python (PyData Seattle 2015)
Deep Learning with Python (PyData Seattle 2015)
Alexander Korbonits
Ios-training-institute-in-mumbai
Ios-training-institute-in-mumbaiIos-training-institute-in-mumbai
Ios-training-institute-in-mumbai
vibrantuser
Alice Software
Alice SoftwareAlice Software
Alice Software
university of education,Lahore
Alice Software
Alice SoftwareAlice Software
Alice Software
university of education,Lahore
ARIHSL Presentation: Today's Tech - What a Practicing Librarian Needs to Know
ARIHSL Presentation: Today's Tech - What a Practicing Librarian Needs to KnowARIHSL Presentation: Today's Tech - What a Practicing Librarian Needs to Know
ARIHSL Presentation: Today's Tech - What a Practicing Librarian Needs to Know
Amanda Izenstark
Method Swizzling with Objective-C
Method Swizzling with Objective-CMethod Swizzling with Objective-C
Method Swizzling with Objective-C
AdamFallon4
Object Oriented Paradigm
Object Oriented ParadigmObject Oriented Paradigm
Object Oriented Paradigm
H端seyin Ergin
Ios development
Ios developmentIos development
Ios development
Shakil Ahmed
Adventures in cross platform ConnectJS / TiConnect 2014
Adventures in cross platform ConnectJS / TiConnect 2014Adventures in cross platform ConnectJS / TiConnect 2014
Adventures in cross platform ConnectJS / TiConnect 2014
Jason Kneen
Doug McCune - Using Open Source Flex and ActionScript Projects
Doug McCune - Using Open Source Flex and ActionScript ProjectsDoug McCune - Using Open Source Flex and ActionScript Projects
Doug McCune - Using Open Source Flex and ActionScript Projects
Doug McCune
Eclipse workshop presentation (March 2016)
Eclipse workshop presentation (March 2016)Eclipse workshop presentation (March 2016)
Eclipse workshop presentation (March 2016)
Miguel Pardal
Managing Memory in Swift (Yes, that's a thing)
Managing Memory in Swift (Yes, that's a thing)Managing Memory in Swift (Yes, that's a thing)
Managing Memory in Swift (Yes, that's a thing)
Carl Brown
Get to know Alice3
Get to know Alice3 Get to know Alice3
Get to know Alice3
SchoolNet SA
Mobile Fest 2018. 仍亠从亠亶 亳亰亠仆从仂. Make your project great again
Mobile Fest 2018. 仍亠从亠亶 亳亰亠仆从仂. Make your project great againMobile Fest 2018. 仍亠从亠亶 亳亰亠仆从仂. Make your project great again
Mobile Fest 2018. 仍亠从亠亶 亳亰亠仆从仂. Make your project great again
MobileFest2018
"Open Mapping on iOS" Justin Miller, MapBox
"Open Mapping on iOS"  Justin Miller, MapBox"Open Mapping on iOS"  Justin Miller, MapBox
"Open Mapping on iOS" Justin Miller, MapBox
Yandex
OOP History and Core Concepts
OOP History and Core ConceptsOOP History and Core Concepts
OOP History and Core Concepts
Nghia Bui Van
Mosaic Fun with OpenOffice Calc
Mosaic Fun with OpenOffice CalcMosaic Fun with OpenOffice Calc
Mosaic Fun with OpenOffice Calc
imacat .
Looking For Xaml In All The Wrong Places
Looking For Xaml In All The Wrong PlacesLooking For Xaml In All The Wrong Places
Looking For Xaml In All The Wrong Places
Adam Hill
Alice ppt ch01
Alice ppt ch01Alice ppt ch01
Alice ppt ch01
barkeshli
Ios-training-institute-in-mumbai
Ios-training-institute-in-mumbaiIos-training-institute-in-mumbai
Ios-training-institute-in-mumbai
vibrantuser
Deep Learning with Python (PyData Seattle 2015)
Deep Learning with Python (PyData Seattle 2015)Deep Learning with Python (PyData Seattle 2015)
Deep Learning with Python (PyData Seattle 2015)
Alexander Korbonits
Ios-training-institute-in-mumbai
Ios-training-institute-in-mumbaiIos-training-institute-in-mumbai
Ios-training-institute-in-mumbai
vibrantuser
ARIHSL Presentation: Today's Tech - What a Practicing Librarian Needs to Know
ARIHSL Presentation: Today's Tech - What a Practicing Librarian Needs to KnowARIHSL Presentation: Today's Tech - What a Practicing Librarian Needs to Know
ARIHSL Presentation: Today's Tech - What a Practicing Librarian Needs to Know
Amanda Izenstark
Method Swizzling with Objective-C
Method Swizzling with Objective-CMethod Swizzling with Objective-C
Method Swizzling with Objective-C
AdamFallon4
Object Oriented Paradigm
Object Oriented ParadigmObject Oriented Paradigm
Object Oriented Paradigm
H端seyin Ergin
Ios development
Ios developmentIos development
Ios development
Shakil Ahmed
Adventures in cross platform ConnectJS / TiConnect 2014
Adventures in cross platform ConnectJS / TiConnect 2014Adventures in cross platform ConnectJS / TiConnect 2014
Adventures in cross platform ConnectJS / TiConnect 2014
Jason Kneen
Doug McCune - Using Open Source Flex and ActionScript Projects
Doug McCune - Using Open Source Flex and ActionScript ProjectsDoug McCune - Using Open Source Flex and ActionScript Projects
Doug McCune - Using Open Source Flex and ActionScript Projects
Doug McCune
Eclipse workshop presentation (March 2016)
Eclipse workshop presentation (March 2016)Eclipse workshop presentation (March 2016)
Eclipse workshop presentation (March 2016)
Miguel Pardal
Managing Memory in Swift (Yes, that's a thing)
Managing Memory in Swift (Yes, that's a thing)Managing Memory in Swift (Yes, that's a thing)
Managing Memory in Swift (Yes, that's a thing)
Carl Brown
Get to know Alice3
Get to know Alice3 Get to know Alice3
Get to know Alice3
SchoolNet SA
Mobile Fest 2018. 仍亠从亠亶 亳亰亠仆从仂. Make your project great again
Mobile Fest 2018. 仍亠从亠亶 亳亰亠仆从仂. Make your project great againMobile Fest 2018. 仍亠从亠亶 亳亰亠仆从仂. Make your project great again
Mobile Fest 2018. 仍亠从亠亶 亳亰亠仆从仂. Make your project great again
MobileFest2018
"Open Mapping on iOS" Justin Miller, MapBox
"Open Mapping on iOS"  Justin Miller, MapBox"Open Mapping on iOS"  Justin Miller, MapBox
"Open Mapping on iOS" Justin Miller, MapBox
Yandex
OOP History and Core Concepts
OOP History and Core ConceptsOOP History and Core Concepts
OOP History and Core Concepts
Nghia Bui Van
Mosaic Fun with OpenOffice Calc
Mosaic Fun with OpenOffice CalcMosaic Fun with OpenOffice Calc
Mosaic Fun with OpenOffice Calc
imacat .
Looking For Xaml In All The Wrong Places
Looking For Xaml In All The Wrong PlacesLooking For Xaml In All The Wrong Places
Looking For Xaml In All The Wrong Places
Adam Hill

More from Muhammad Bilal Tariq (6)

Relational database management system
Relational database management systemRelational database management system
Relational database management system
Muhammad Bilal Tariq
Ch1-Operating System Concepts
Ch1-Operating System ConceptsCh1-Operating System Concepts
Ch1-Operating System Concepts
Muhammad Bilal Tariq
Ch1-Operating System Concept
Ch1-Operating System ConceptCh1-Operating System Concept
Ch1-Operating System Concept
Muhammad Bilal Tariq
INTRODUCTION TO DATABASE
INTRODUCTION TO DATABASEINTRODUCTION TO DATABASE
INTRODUCTION TO DATABASE
Muhammad Bilal Tariq
Leadership
LeadershipLeadership
Leadership
Muhammad Bilal Tariq
Exponential probability distribution
Exponential probability distributionExponential probability distribution
Exponential probability distribution
Muhammad Bilal Tariq

Recently uploaded (20)

Presentation2 ROHIT Photochemitry 3rd sem.pptx
Presentation2 ROHIT  Photochemitry 3rd sem.pptxPresentation2 ROHIT  Photochemitry 3rd sem.pptx
Presentation2 ROHIT Photochemitry 3rd sem.pptx
rohitverma43215
Mutation and its types (Point, Silent, Mis sense and Non sense mutations)
Mutation and its types (Point, Silent, Mis sense and Non sense mutations)Mutation and its types (Point, Silent, Mis sense and Non sense mutations)
Mutation and its types (Point, Silent, Mis sense and Non sense mutations)
Anoja Kurian
basic tissuse oral epithelium the classifications and subunits
basic tissuse oral epithelium the classifications and subunitsbasic tissuse oral epithelium the classifications and subunits
basic tissuse oral epithelium the classifications and subunits
jemimahrachel1299
Sciences of Europe No 161 (2025)
Sciences of Europe No 161 (2025)Sciences of Europe No 161 (2025)
Sciences of Europe No 161 (2025)
Sciences of Europe
Types of natural disasters and their effects on people and the earth
Types of natural disasters and their effects on people and the earthTypes of natural disasters and their effects on people and the earth
Types of natural disasters and their effects on people and the earth
brhaley
SWOT Analysis AND ITS TECHNIQUES FOR SWOT ANALYSIS .pptx
SWOT Analysis AND ITS TECHNIQUES FOR SWOT ANALYSIS .pptxSWOT Analysis AND ITS TECHNIQUES FOR SWOT ANALYSIS .pptx
SWOT Analysis AND ITS TECHNIQUES FOR SWOT ANALYSIS .pptx
faizantahir666
Responsible Use of Research Metrics Module Launch
Responsible Use of Research Metrics Module LaunchResponsible Use of Research Metrics Module Launch
Responsible Use of Research Metrics Module Launch
dri_ireland
EDIC Old Exames Q 3.pdfs fefeegh5uyttbtrr
EDIC Old Exames Q 3.pdfs fefeegh5uyttbtrrEDIC Old Exames Q 3.pdfs fefeegh5uyttbtrr
EDIC Old Exames Q 3.pdfs fefeegh5uyttbtrr
EmanEssa14
Polymer Composites Classification, Reinforcements, Matrices,.pptx
Polymer Composites Classification, Reinforcements, Matrices,.pptxPolymer Composites Classification, Reinforcements, Matrices,.pptx
Polymer Composites Classification, Reinforcements, Matrices,.pptx
JinnJinnkiJaddu
Vaccines: types, preparations, efficacies and recent developments.pptx
Vaccines: types, preparations, efficacies and recent developments.pptxVaccines: types, preparations, efficacies and recent developments.pptx
Vaccines: types, preparations, efficacies and recent developments.pptx
krishna moorthy
musclesoffacialexpression-Lecture by Dr Bassana.pptx
musclesoffacialexpression-Lecture by Dr Bassana.pptxmusclesoffacialexpression-Lecture by Dr Bassana.pptx
musclesoffacialexpression-Lecture by Dr Bassana.pptx
baffourprince2016
SWOT Analysis AND IMPORTANCE OF SWOT ANALYSIS.pptx
SWOT Analysis AND IMPORTANCE OF SWOT ANALYSIS.pptxSWOT Analysis AND IMPORTANCE OF SWOT ANALYSIS.pptx
SWOT Analysis AND IMPORTANCE OF SWOT ANALYSIS.pptx
faizantahir666
natural producghfhhgfhffft 4sem ppt.pptx
natural producghfhhgfhffft 4sem ppt.pptxnatural producghfhhgfhffft 4sem ppt.pptx
natural producghfhhgfhffft 4sem ppt.pptx
rohitverma43215
Lecture 1 - Overview of Go Language 1.pdf
Lecture 1 - Overview of Go Language 1.pdfLecture 1 - Overview of Go Language 1.pdf
Lecture 1 - Overview of Go Language 1.pdf
daomaithuhuyen1273
Importance and Essentials and Necessities of Cell and Molecular Biology
Importance and Essentials and Necessities of Cell and Molecular BiologyImportance and Essentials and Necessities of Cell and Molecular Biology
Importance and Essentials and Necessities of Cell and Molecular Biology
johnfreeguydoe
Vaccine Delivery : Strategies & Future
Vaccine Delivery :  Strategies &  FutureVaccine Delivery :  Strategies &  Future
Vaccine Delivery : Strategies & Future
LubdhaBadgujar
physiology of endocrine system ;pancreas
physiology of endocrine system ;pancreasphysiology of endocrine system ;pancreas
physiology of endocrine system ;pancreas
dina merzeban
Actinobacterium Producing Antimicrobials Against Drug-Resistant Bacteria
Actinobacterium Producing Antimicrobials Against Drug-Resistant BacteriaActinobacterium Producing Antimicrobials Against Drug-Resistant Bacteria
Actinobacterium Producing Antimicrobials Against Drug-Resistant Bacteria
Abdulmajid Almasabi
Comic Strip Hb, do you take O2 as your wife.pdf
Comic Strip Hb, do you take O2 as your wife.pdfComic Strip Hb, do you take O2 as your wife.pdf
Comic Strip Hb, do you take O2 as your wife.pdf
nampa1
IMMUNOMODULATORS: IMMUNOSTIMULATION AND IMMUNOSUPPRESSION .pptx
IMMUNOMODULATORS: IMMUNOSTIMULATION AND IMMUNOSUPPRESSION .pptxIMMUNOMODULATORS: IMMUNOSTIMULATION AND IMMUNOSUPPRESSION .pptx
IMMUNOMODULATORS: IMMUNOSTIMULATION AND IMMUNOSUPPRESSION .pptx
karishmaduhijod1
Presentation2 ROHIT Photochemitry 3rd sem.pptx
Presentation2 ROHIT  Photochemitry 3rd sem.pptxPresentation2 ROHIT  Photochemitry 3rd sem.pptx
Presentation2 ROHIT Photochemitry 3rd sem.pptx
rohitverma43215
Mutation and its types (Point, Silent, Mis sense and Non sense mutations)
Mutation and its types (Point, Silent, Mis sense and Non sense mutations)Mutation and its types (Point, Silent, Mis sense and Non sense mutations)
Mutation and its types (Point, Silent, Mis sense and Non sense mutations)
Anoja Kurian
basic tissuse oral epithelium the classifications and subunits
basic tissuse oral epithelium the classifications and subunitsbasic tissuse oral epithelium the classifications and subunits
basic tissuse oral epithelium the classifications and subunits
jemimahrachel1299
Sciences of Europe No 161 (2025)
Sciences of Europe No 161 (2025)Sciences of Europe No 161 (2025)
Sciences of Europe No 161 (2025)
Sciences of Europe
Types of natural disasters and their effects on people and the earth
Types of natural disasters and their effects on people and the earthTypes of natural disasters and their effects on people and the earth
Types of natural disasters and their effects on people and the earth
brhaley
SWOT Analysis AND ITS TECHNIQUES FOR SWOT ANALYSIS .pptx
SWOT Analysis AND ITS TECHNIQUES FOR SWOT ANALYSIS .pptxSWOT Analysis AND ITS TECHNIQUES FOR SWOT ANALYSIS .pptx
SWOT Analysis AND ITS TECHNIQUES FOR SWOT ANALYSIS .pptx
faizantahir666
Responsible Use of Research Metrics Module Launch
Responsible Use of Research Metrics Module LaunchResponsible Use of Research Metrics Module Launch
Responsible Use of Research Metrics Module Launch
dri_ireland
EDIC Old Exames Q 3.pdfs fefeegh5uyttbtrr
EDIC Old Exames Q 3.pdfs fefeegh5uyttbtrrEDIC Old Exames Q 3.pdfs fefeegh5uyttbtrr
EDIC Old Exames Q 3.pdfs fefeegh5uyttbtrr
EmanEssa14
Polymer Composites Classification, Reinforcements, Matrices,.pptx
Polymer Composites Classification, Reinforcements, Matrices,.pptxPolymer Composites Classification, Reinforcements, Matrices,.pptx
Polymer Composites Classification, Reinforcements, Matrices,.pptx
JinnJinnkiJaddu
Vaccines: types, preparations, efficacies and recent developments.pptx
Vaccines: types, preparations, efficacies and recent developments.pptxVaccines: types, preparations, efficacies and recent developments.pptx
Vaccines: types, preparations, efficacies and recent developments.pptx
krishna moorthy
musclesoffacialexpression-Lecture by Dr Bassana.pptx
musclesoffacialexpression-Lecture by Dr Bassana.pptxmusclesoffacialexpression-Lecture by Dr Bassana.pptx
musclesoffacialexpression-Lecture by Dr Bassana.pptx
baffourprince2016
SWOT Analysis AND IMPORTANCE OF SWOT ANALYSIS.pptx
SWOT Analysis AND IMPORTANCE OF SWOT ANALYSIS.pptxSWOT Analysis AND IMPORTANCE OF SWOT ANALYSIS.pptx
SWOT Analysis AND IMPORTANCE OF SWOT ANALYSIS.pptx
faizantahir666
natural producghfhhgfhffft 4sem ppt.pptx
natural producghfhhgfhffft 4sem ppt.pptxnatural producghfhhgfhffft 4sem ppt.pptx
natural producghfhhgfhffft 4sem ppt.pptx
rohitverma43215
Lecture 1 - Overview of Go Language 1.pdf
Lecture 1 - Overview of Go Language 1.pdfLecture 1 - Overview of Go Language 1.pdf
Lecture 1 - Overview of Go Language 1.pdf
daomaithuhuyen1273
Importance and Essentials and Necessities of Cell and Molecular Biology
Importance and Essentials and Necessities of Cell and Molecular BiologyImportance and Essentials and Necessities of Cell and Molecular Biology
Importance and Essentials and Necessities of Cell and Molecular Biology
johnfreeguydoe
Vaccine Delivery : Strategies & Future
Vaccine Delivery :  Strategies &  FutureVaccine Delivery :  Strategies &  Future
Vaccine Delivery : Strategies & Future
LubdhaBadgujar
physiology of endocrine system ;pancreas
physiology of endocrine system ;pancreasphysiology of endocrine system ;pancreas
physiology of endocrine system ;pancreas
dina merzeban
Actinobacterium Producing Antimicrobials Against Drug-Resistant Bacteria
Actinobacterium Producing Antimicrobials Against Drug-Resistant BacteriaActinobacterium Producing Antimicrobials Against Drug-Resistant Bacteria
Actinobacterium Producing Antimicrobials Against Drug-Resistant Bacteria
Abdulmajid Almasabi
Comic Strip Hb, do you take O2 as your wife.pdf
Comic Strip Hb, do you take O2 as your wife.pdfComic Strip Hb, do you take O2 as your wife.pdf
Comic Strip Hb, do you take O2 as your wife.pdf
nampa1
IMMUNOMODULATORS: IMMUNOSTIMULATION AND IMMUNOSUPPRESSION .pptx
IMMUNOMODULATORS: IMMUNOSTIMULATION AND IMMUNOSUPPRESSION .pptxIMMUNOMODULATORS: IMMUNOSTIMULATION AND IMMUNOSUPPRESSION .pptx
IMMUNOMODULATORS: IMMUNOSTIMULATION AND IMMUNOSUPPRESSION .pptx
karishmaduhijod1

Visual programming

  • 1. CS320n Elements of Visual Programming Introduction to Alice Mike Scott (際際滷s 1-1)
  • 2. Visual Programming Introduction to Alice 2 What We Will Do Today look at the Alice programming environment create some simple programs in Alice
  • 3. Visual Programming Introduction to Alice 3 What is Alice? Named in honor of Lewis Carrolls (pen name) Alice in Wonderland Charles Lutwidge Dodgson was also a mathematician and logician A modern programming tool purpose of tool, learn how to program, write algorithms 3-D graphics 3-D models of objects Animation Objects can be made to move around virtual world (a simulation or a video game. Simple Pixar.)
  • 4. Visual Programming Introduction to Alice 4 Computer Programs General purpose programming languages can be used for almost any task Alice is not a general purpose programming language. It is an application specific language designed for a specific task, creating 3D animations lots of application specific languages. Example: language for working with DNA data
  • 5. Visual Programming Introduction to Alice 5 Fundamental Tools All languages contain these elements 1. list of instructions Pack lunch, pack snack, put homework in backpack. 2. decision making If I didnt shave yesterday, shave today. 3. repetition of behavior Do a load of laundry until there is no more dirty laundry. 4. modularization. Big rocks into little rocks. To do a load of laundry: gather clothes, get clothes right- side out, put clothes of similar color into washing machine 5. Generalization: Solve many different problems with one set of instructions 6. Compute a result How much is it going to cost to fill up my car with gas?
  • 6. Visual Programming Introduction to Alice 6 What does Alice run on? Alice is free. Alice is written in Java only working versions are for PCs and Macs with OSX 10.3 or higher (relatively new, may still have bugs) Sorry, no Linux, yet the book comes with a copy of Alice for Windows machines www.alice.org also on the computers in the CS Elements lab
  • 7. Visual Programming Introduction to Alice 7 Fast Start Up Can quickly learn to create a simple animation in a matter of minutes a non-trivial animation in a few class periods Can learn to use the Alice interface in a few class periods if you do a couple of exercises at home
  • 8. Visual Programming Introduction to Alice 8 Installing Alice If you want to install Alice on you computer at home use the CD that comes with the textbook CD installation is straightforward download Alice from the web http://www.alice.org/downloads/authoringtool/ file format is .zip must unzip file using a program such as winzip problems? post to newsgroup
  • 9. Visual Programming Introduction to Alice 9 Memory Management Alice automatically manages memory But, writing and testing an animation is an intense load on the computing system a crash can occur. Best solution: Alice (the program) reminds you every so often so save your work save your programs often! if working in lab when you logout the computer is wiped -> save to your account or to a backup system such as a memory stick
  • 10. Visual Programming Introduction to Alice 10 The Power of Alice Automatically keeps track of 3-D objects what objects are in the virtual world types of objects positions of objects in the world
  • 11. Visual Programming Introduction to Alice 11 Demo Starting Alice Loading a World Running A World Saving a World How to Exit
  • 12. Visual Programming Introduction to Alice 12 The World Alice Programs / Movies take place in a virtual world When you start a new world in Alice you select the background The world consists of a sky and the ground Cant be changed after creating the world the world is not infinite DEMO (I dont like roller coasters any more)
  • 13. Visual Programming Introduction to Alice 13 Objects in Alice Objects already exist. Hundreds of them
  • 14. Visual Programming Introduction to Alice 14 Program an Object
  • 15. Visual Programming Introduction to Alice 15 Where Do Objects Come From? They are pre built creating 3D objects is another area of computing and graphic design Sources of 3D objects the local gallery that comes with the software Alice web gallery How are objects added to the world?
  • 16. Visual Programming Introduction to Alice 16 Adding Objects Click on the green Add Objects button World expands and local gallery displayed
  • 17. Visual Programming Introduction to Alice 17 Adding Objects Local gallery divided into a directory based on subject add instances of objects to world by dragging and dropping or click on object and select add instance option
  • 18. Visual Programming Introduction to Alice 18 Objects in the World Can have multiple instances of objects from the same class in the World class: like a cookie cutter objects: like the cookies star cookie cutter star cookie class star cookies star cookie objects
  • 19. Visual Programming Introduction to Alice 19 Objects in the World penguin class penguin objects in a virtual world
  • 20. Visual Programming Introduction to Alice 20 Objects in the World The Objects that are present in the current world are listed in the Object Tree The top left panel in the Alice programming environment Every world comes with a light, a camera (point of view for the movie when played), and the ground
  • 21. Visual Programming Introduction to Alice 21 Object Dimensions Objects in Alice worlds are 3 dimensional height width depth
  • 22. Visual Programming Introduction to Alice 22 Object Position Objects are positioned in 3-D space Have six degrees of freedom (directions of movement)
  • 23. Visual Programming Introduction to Alice 23 Objects Know Relative Directions Yellow box around penguin is its bounding box light blue line is up/down pink line is left/right dark blue line is forward backward DEMO
  • 24. Visual Programming Introduction to Alice 24 Exercises if you want to work at home, install Alice on your computer Complete Appendix A, Part 1, using Alice a walkthrough of using Alice Complete the tutorials that come with Alice
  • 25. Visual Programming Introduction to Alice 25 Starting Tutorials