Chapter 7 Introduction to High-Level Language Programming.

Slides:



Advertisements
Similar presentations
Chapter 13 Graphics.
Advertisements

Applets and Graphics.
Copyright 2006 by Pearson Education 1 Building Java Programs Supplement 3G: Graphics.
2006 by Jim X. Chen: 1.1. Review –Graphics commands specify straight lines or other geometric primitives that are scan-converted.
Basic Raster Graphics Algorithms for Drawing 2D Primitives
Graphics Chapter 16.  If you want to draw shapes such as a bar chart, a clock, or a stop sign, how do you do it?
PHY-102 SAPIntroductory GraphicsSlide 1 Introductory Graphics In this section we will learn how about how to draw graphics on the screen in Java:  Drawing.
LAB SESSION 7 Graphical user interface Applet fundamentals Methods in applets Execution of an applet Graphics class.
Computer Graphics Tz-Huan Huang National Taiwan University (Slides are based on Prof. Chen’s)
CSC1401 Drawing in Java - 2. Reminder from last class How do you save your modified picture? String filename = …; Picture stevePicture = new Picture(filename);
Chapter 7 Introduction to High-Level Language Programming.
©2004 Brooks/Cole Applets Graphics & GUIs. Figures ©2004 Brooks/Cole CS 119: Intro to JavaFall 2005 Graphical Programs Most applications these days are.
 2003 Prentice Hall, Inc. All rights reserved. 1 Chapter 3 - Introduction to Java Applets Outline 3.1 Introduction 3.2 Sample Applets from the Java 2.
Chapter 8: Introduction to High-level Language Programming Invitation to Computer Science, C++ Version, Third Edition.
1 L37 Graphics and Java 2D™ (2). 2 OBJECTIVES To use methods of class Graphics to draw lines,  rectangles,  rectangles with rounded corners,  three-dimensional.
Copyright 2006 by Pearson Education 1 Building Java Programs Supplement 3G: Graphics.
Chapter 8: Introduction to High-Level Language Programming Invitation to Computer Science, Java Version, Third Edition.
1 Applets Chapter 1 To understand:  why applets are used to extend the capabilities of Web pages  how an applet is executed and know about the restrictions.
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming.
©The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 4 th Ed Chapter Chapter 5 Applets and Graphics.
Chapter 8: Introduction to High-level Language Programming Invitation to Computer Science, C++ Version, Third Edition.
Introduction to OpenGL. What is OpenGL OpenGL is a low-level software interface to graphics hardware No commands for performing windowing tasks or obtaining.
About the Presentations The presentations cover the objectives found in the opening of each chapter. All chapter objectives are listed in the beginning.
Chapter 8: Introduction to High-level Language Programming Invitation to Computer Science, C++ Version, Third Edition.
Chapter 8: Introduction to High-Level Language Programming Invitation to Computer Science, C++ Version, Fourth Edition.
An Overview of Computers and Programming
Desktop Publishing Features Designing Documents. Publication Terms  Graphics - Objects used to convey a message.  Multiple Columns - Layout used to.
Chapter Introduction to Computers and Programming 1.
Chapter 3 Working with Symbols and Interactivity.
1 Bitmap Graphics It is represented by a dot pattern in which each dot is called a pixel. Each pixel can be in any one of the colors available and the.
Invitation to Computer Science 5th Edition
©The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 4 th Ed Chapter Java Applets What is an Applet? How do you create.
High-Level Programming Languages: C++
Dr. S.M. Malaek Assistant: M. Younesi
Chapter 1: Introduction to Computers and Programming.
Copyright © 2009 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 1: Introduction to Computers and Programming.
Java Software Solutions Lewis and Loftus Chapter 7 1 Copyright 1997 by John Lewis and William Loftus. All rights reserved. Graphics -- Introduction The.
Invitation to Computer Science 5 th Edition Chapter C# Programming in C#
Invitation to Computer Science 6th Edition
Computing with C# and the.NET Framework Chapter 1 An Introduction to Computing with C# ©2003, 2011 Art Gittleman.
© 2011 Delmar, Cengage Learning Chapter 3 Working with Symbols and Interactivity.
Working with Symbols and Interactivity
Chapter 3 Syntax, Errors, and Debugging Fundamentals of Java.
Java Programming, 2E Introductory Concepts and Techniques Chapter 1 An Introduction to Java and Program Design.
1 Introduction to Computer Graphics SEN Introduction to OpenGL Graphics Applications.
Lecture 15: Intro to Graphics Yoni Fridman 7/25/01 7/25/01.
Introduction to Java Simple Graphics. Objects and Methods Recall that a method is an action which can be performed by an object. –The action takes place.
Invitation to Computer Science 5 th Edition Chapter C++ Programming in C++
Computer Graphics Chapter 6 Andreas Savva. 2 Interactive Graphics Graphics provides one of the most natural means of communicating with a computer. Interactive.
Visual C++ Programming: Concepts and Projects Chapter 11B: Pointers (Tutorial)
Chapter 8: Introduction to High-level Language Programming Invitation to Computer Science, C++ Version, Third Edition.
Chapter 8: Introduction to High-Level Language Programming Invitation to Computer Science, Java Version, Third Edition.
1 Building Java Programs Supplement 3G: Graphics These lecture notes are copyright (C) Marty Stepp and Stuart Reges, They may not be rehosted, sold,
(C) 2010 Pearson Education, Inc. All rights reserved.  Class Graphics (from package java.awt) provides various methods for drawing text and shapes onto.
Graphics: Conceptual Model Real Object Human Eye Display Device Graphics System Synthetic Model Synthetic Camera Real Light Synthetic Light Source.
Merete S COLLEGEFACULTY OF ENGINEERING & SCIENCE Graphics ikt403 – Object-Oriented Software Development.
Painting (Chapter 12) Java Certification Study Group January 25, 1999 Mark Roth.
Introduction to OOP CPS235: Introduction.
Introduction to Graphics. Graphical objects To draw pictures, we will use three classes of objects: –DrawingPanel : A window on the screen. –Graphics.
Chapter 1: Introduction to Computers and Programming.
CPCS 391 Computer Graphics Lab One. Computer Graphics Using Java What is Computer Graphics: Computer graphics are graphics created using computers and,
Invitation to Computer Science 5 th Edition Chapter Ada Programming in Ada.
Programming Logic and Design Seventh Edition Chapter 1 An Overview of Computers and Programming.
Computer Graphics (Fall 2003) COMS 4160, Lecture 5: OpenGL 1 Ravi Ramamoorthi Many slides courtesy Greg Humphreys.
Intro to Graphics from Chapter 2 of Java Software Solutions
Visit for more Learning Resources
Flash Interface, Commands and Functions
Basic Graphics Chapter 5 3/19/15 Thursday Section Only
Example: Card Game Create a class called “Card”
Chapter 8: Introduction to High-Level Language Programming
Presentation transcript:

Chapter 7 Introduction to High-Level Language Programming

High Level Languages – Figure 7.1 Transitions of a High-Level Language Program

Virtual Data Storage – Figure 7.6 A 12-Element Array Hits

Virtual Data Storage – Figure 7.7 A Virtual 2 x 3 Table

Virtual Data Storage – Figure 7.7 The 2 x 3 Table Stored In Memory

Control Statements – Figure 7. 9 Sequential Flow of Control

Control Statements – Figure Conditional Flow of Control (If-Else)

Control Statements – Figure If-Else with Empty Else

Control Statements – Figure While Loop

Meeting Expectations – Figure Each Target Machine Has a Separate Compiler

Meeting Expectations – Figure 7.21 – Java Compiler, Java Bytecode Interpreters

Managing Complexity – Figure 7.22A – Structure Charts

Managing Complexity – Figure 7.22B – Structure Charts

Managing Complexity – Figure 7.23 Methods In The Circle Class

Object-Oriented Programming – Figure 7.30 The PIE of OOP

Java and OOP – Figure 7.34 – A Hierarchy of Geometric Classes

Graphical Programming - The Importance of Visualization

Graphical Programming – Figure Visualization of a Three-Dimensional Surface

Graphic Primitives – Figure Pixel Numbering System in a Bit Mapped Display

Graphic Primitives – Figure Displaying of Information on the Terminal

7.9.3 Graphics Software – A Window or a Frame in Java

A DrawLine (int x1, int y1, int x 2, int y 2). This Draws A Straight Line From Point (x1, y1) On The Screen To Point (x2, y2.)

Graphics Software– Command: drawLine (1,1,4,4); Sets Four Pixels in the Frame Buffer

Graphic Software– Using Command drawOval (int x, int y, int width, int height). This Draws an Oval Within a Rectangle

Graphics Software – No Entry Sign - Set Color Command From the Color Class

Graphics Software – Using Commands, drawOval, drawLine, and Set Color, We Can Change The Stop Sign

Graphics Software – Using Commands of drawString and drawLine Will Produce This Image.

Graphics Software – drawRoundRectangle (int x, int y, int width, int height, int arcWidth, int arcHeight).

Graphics Software – A Filled Shape Rather Than An Outline

Graphics Software – Using the Command of fillOval (80, 80, 300, 200) Note The Circle Is Outside The Window – This Is Called Clipping

Practice Problems – Write The Sequence of Commands to Draw The House On This Screen

Exercises – Given the Declaration int [ ] [ ] table = new int [5] [3]: How Would You Refer To This Marked Cell

Exercises – Using the drawLine Command Draw An Isosceles Triangle

Exercises – Create three labeled Rectangular Buttons

Exercises – Create the image of a “Teeter-Totter”