Lecture 7: Objects and Interaction 1  Principles of Interactive Graphics  CMSCD2012  Dr David England, Room 718,  ex 2271 

Slides:



Advertisements
Similar presentations
Introduction to Java 2 Programming
Advertisements

Designing a Graphical User Interface (GUI) 10 IST – Topic 6.
IMS1805 Systems Analysis Topic 3: Doing Analysis (continued from previous weeks)
Object-Oriented Application Development Using VB.NET 1 Chapter 5 Object-Oriented Analysis and Design.
Chapter 1 Object-Oriented System Development
Introduction To System Analysis and Design
Object-Oriented Design & Programming Fawzi Emad Chau-Wen Tseng Department of Computer Science University of Maryland, College Park.
Chapter 6 Graphical User Interface (GUI) and Object-Oriented Design (OOD)
1 CS1001 Lecture Overview Homework 3 Homework 3 Project/Paper Project/Paper Object Oriented Design Object Oriented Design.
Object-Oriented Databases v OO systems associated with – graphical user interface (GUI) – powerful modeling techniques – advanced data management capabilities.
Object Oriented System Development with VB .NET
R R R CSE870: Advanced Software Engineering: Frameworks (Cheng, Sp2003)1 Frameworks A Brief Introduction.
PROCESS MODELING Transform Description. A model is a representation of reality. Just as a picture is worth a thousand words, most models are pictorial.
HST 952 Computing for Biomedical Scientists Lecture 2.
Essentials of Interactive Computer Graphics: Concepts and Implementation K. Sung, P. Shirley, S. Baer Intro and Chapter 1 Goals Give student some idea.
1 CMSC 132: Object-Oriented Programming II Software Development IV Department of Computer Science University of Maryland, College Park.
Object-Oriented Analysis and Design
ASP.NET Programming with C# and SQL Server First Edition
Sharif University of Technology Session # 7.  Contents  Systems Analysis and Design  Planning the approach  Asking questions and collecting data 
C++ fundamentals.
Tutorial 6 Forms Section A - Working with Forms in JavaScript.
1 Object-Oriented Software Engineering CIS 375 Bruce R. Maxim UM-Dearborn.
Graphical Tree-Based Scientific Calculator: CalcuWiz Will Ryan Christian Braunlich.
Programming Paradigms Imperative programming Functional programming Logic programming Event-driven programming Object-oriented programming A programming.
The Project AH Computing. Functional Requirements  What the product must do!  Examples attractive welcome screen all options available as clickable.
Lecture Set 3 Introduction to Visual Basic Concepts Part A – User Interfaces and Windows Forms – The Toolbox.
Platforms for Learning in Computer Science July 28, 2005.
The Design Discipline.
ACM/JETT Workshop - August 4-5, ExceptionHandling and User Interfaces (Event Delegation, Inner classes) using Swing.
CS 0004 –Lecture 1 Wednesday, Jan 5 th, 2011 Roxana Gheorghiu.
An Object-Oriented Approach to Programming Logic and Design
COMPUTER PROGRAMMING Source: Computing Concepts (the I-series) by Haag, Cummings, and Rhea, McGraw-Hill/Irwin, 2002.
OO (Object Oriented) Programming Chapter 21 IB103 Week 12.
School of Computer Science & Information Technology G6DICP - Lecture 22 The Theory of Object Oriented Programming.
Java Classes Using Java Classes Introduction to UML.
Lecture 5: Interaction 1  Principles of Interactive Graphics  CMSCD2012  Dr David England, Room 711,  ex 2271 
Chapter 8: Writing Graphical User Interfaces Visual Basic.NET Programming: From Problem Analysis to Program Design.
Introduction To System Analysis and Design
(c) University of Washington08-1 CSC 143 Models and Views Reading: Ch. 18.
C H A P T E R T E N Event-Driven Programming Programming Languages – Principles and Paradigms by Allen Tucker, Robert Noonan.
Copyright 2003 Scott/Jones Publishing Standard Version of Starting Out with C++, 4th Edition Chapter 13 Introduction to Classes.
Lecture 6: 3D graphics Concepts 1  Principles of Interactive Graphics  CMSCD2012  Dr David England, Room 718,  ex 2271 
School of Computer Science & Information Technology G6DICP - Lecture 17 GUI (Graphical User Interface) Programming.
Graphic User Interface. Graphic User Interface (GUI) Most of us interact with computers using GUIs. GUIs are visual representations of the actions you.
Lecture 11: Exam Revision 1  Principles of Interactive Graphics  CMSCD2012  Dr David England, Room 718,  ex 2271  Coursework.
Object-Oriented Design Simple Program Design Third Edition A Step-by-Step Approach 11.
Swing MVC Application Layering A Layer is a collection of components that Perform similar tasks. Perform similar tasks. Isolate implementation details.
Lection №5 Modern integrated development environment.
Basic OOP Concepts and Terms. In this class, we will cover: Objects and examples of different object types Classes and how they relate to objects Object.
Concurrent Programming and Threads Threads Blocking a User Interface.
Model View Controller A Pattern that Many People Think They Understand, But Has A Couple Meanings.
Dale Roberts Introduction to Visual Programming Dale Roberts, Lecturer Computer Science, IUPUI Department of Computer and.
Introduction to Computer Graphics 1  Principles of Interactive Graphics  CMSCD2012  Dr David England, Room 711,  ex 2271 
Lecture 2: Some definitions of terms 1  Principles of Interactive Graphics  CMSCD2012  Dr David England, Room 711,  ex 2271 
How the Session Works Outline Practical on arrival Talk 1 Reflect on practical Clarify concepts Practical exercises at your own pace Talk 2: Further concepts.
Build-A-Button Glenn G. Chappell U. of Alaska Fairbanks CS 381 Lecture Notes Wednesday, October 8, 2003.
CPSC 871 John D. McGregor Module 3 Session 1 Architecture.
CITA 342 Section 2 Visual Programming. Allows the use of visual expressions (such as graphics, drawings, or animation) in the process of programming.
Dr D. Greer, Queens University Belfast )Chapter Six 1 Software Engineering Chapter Six Software Design Quality Learning Outcomes.
Lesson 1 1 LESSON 1 l Background information l Introduction to Java Introduction and a Taste of Java.
Next Back MAP MAP F-1 Management Information Systems for the Information Age Second Canadian Edition Copyright 2004 The McGraw-Hill Companies, Inc. All.
OOPS CONCEPT.  OOPS  Benefits of OOPs  OOPs Principles  Class  Object Objectives.
Object Oriented Programming Course Introduction Dr. Mike Spann
High degree of user interaction Interactive Systems: Model View Controller Presentation-abstraction-control.
Object-Orientated Programming
INF230 Basics in C# Programming
Chapter 8: Writing Graphical User Interfaces
MVC and other n-tier Architectures
Object Oriented Concepts -I
Presentation transcript:

Lecture 7: Objects and Interaction 1  Principles of Interactive Graphics  CMSCD2012  Dr David England, Room 718,  ex 2271  / /  Web page includes: announcements, handouts, web links, reading hints, frequently asked questions

Lecture 7: Objects and Interaction 2 Courseworks  Coursework 1 admin  Hand in your design and code to the Campus Office  Do your demo between 3 and 5pm today  If you cannot do the demo just hand in what you have and ask me about things you did not understand  Coursework 2  Task will be to design and create a 2D controllers for a 3D object  part 1: design and implement simple buttons to control the attributes of the 3D object  part 2: design and implement scrollbars to control the attributes  Optional: Exploit OO techniques to manage design and code

Lecture 7: Objects and Interaction 3 Today’s Lecture: 3D concepts  Object Oriented Design, (OOD) and Computer Graphics  How OOD has enabled the Graphical User Interface revolution  Designing your own objects in OOD  Background for coursework 2

Lecture 7: Objects and Interaction 4 Object Oriented Design  In CY2001 you will have come across concepts such as  Defining Classes and Objects  Encapsulation (private variables and functions for classes)  Polymorphism - functions with the same name but different parameters  Moving from OO design to OO Programming  Abstraction (to different levels) is the main technique of problem solving in Computer Science  OOD works by abstracting out the essential classes of objects in a problem, identifying their attributes and their functionality

Lecture 7: Objects and Interaction 5 Object Oriented Design...  “… the hype surrounding OOSD looks more like reality and that adopting OOSD may indeed be worth the related time, effort and cost.” R Johnson CACM October 2000  OOD and OOP help control the complexity of larger systems development  In your own programs you will have seen the Display() function grow in size with the complexity of the graphical scene  How could you have use OOD and OOP to control and manage this growth? (we’ll come back to this)

Lecture 7: Objects and Interaction 6 OO Graphical User Interfaces - GUI  Smalltalk 80 was the first complete object-oriented programming environment.  Everything in Smalltalk-80 is an object, from integers upwards  The designers chose to split an application up into three parts  The View - the graphical part  The Controller - the input handling part  The Model - the logical part of the application (text handling, database handling or whatever)  Objects in the Controller (e.g. a menu handler) send messages to the Model to do some calculation, which then sends a message to update the View.

Lecture 7: Objects and Interaction 7 OO Graphical User Interfaces ….  The same model - MVC - can be seen in the design and implementation of current GUI toolkits  Java Swing  Microsoft Foundation Classes (MFC)  Swing and MFC put the Controller and View together  MFC has a Document/View structure  Separating the Document and View parts of an application mean that different teams can work on the different parts  The GUI or View might require 50 to 90% of the development effort of a whole project!

Lecture 7: Objects and Interaction 8 Designing your own Graphical Objects  OpenGL is designed around the idea of sending commands down a graphical pipeline  This maybe a good way of developing graphically intense programs such as games  While this reflects the underlying hardware it is not always the best way to program all graphical applications  In your coursework you may have split up the display() function to call other functions to draw the parts of the scene  For example, a dial() function which could draw a new dial in a different location

Lecture 7: Objects and Interaction 9 Designing your own Graphical Objects...  The dial() function could be extended to further parameters such as  Colour of border and background  Radius  Range of dial readings  Division of dial readings  Colour and size of value indicator  Font of dial readings  and so on

Lecture 7: Objects and Interaction 10 Designing your own Graphical Objects...  Or we could take advantage of OOD and design a Dial Class comprising  Private attribute of the attributes listed above  An attribute for the current_pointer value  Constructors to create a new Dial object  A draw function (hiding the OpenGL implementation)  An update function to change current_pointer and redraw the pointer  The rest of the program would then only communicate with the dial via speed_dial.setCurrentPointer(int value);

Lecture 7: Objects and Interaction 11 Designing your own Graphical Objects...  Think for a moment of what other objects in your scene you could create classes for  What would be their attributes?  What methods would be needed?  What attributes would be exposed to the rest of the program to update your object?  For example  Dials and other instruments, radar displays, indicator lamps, external scenery  Kitchen objects as part of a library for a kitchen design program

Lecture 7: Objects and Interaction 12 Resources for Coursework 2  Use glutSolidCube(), or other GLUT convenience routines, to create a 3D object  The left mouse button generates the input events when over a button or scrollbar area - see the functions mouse() and motion() in inputevents.cpp  You have to manage the state between the different mouse events in a button or scrollbar  You could exploit OOD/OOP in reusing buttons and scrollbars

Lecture 7: Objects and Interaction 13 Next Week  We will start to look in more detail at some of the principles of 3D graphics