1 Sung-Ju Kang Department of Physics Kangwon National University Basic Concept of The Computer Graphic. For the investigation of the physical problem by.

Slides:



Advertisements
Similar presentations
 putpixel function plots a pixel at location (x, y) of specified color.  Declaration :- void putpixel(int x, int y, int color);
Advertisements

Graphics Shapes. Setup for using graphics You have to import the graphics library You can use either “import graphics” or “from graphics import *” or.
Line Drawing Algorithms
Functions. COMP104 Functions / Slide 2 Introduction to Functions * A complex problem is often easier to solve by dividing it into several smaller parts,
BGI graphics library And Visual Studio.
Graphics in MS-DOS Environment LEE HUN HEE. 1.Real Coordinate and Windows Coordinate ● Real Coordinate ->(x,y) ● Windows Coordinate ->(wx,wy) ∴ (x,y)->(wx,wy)
Character and String definitions, algorithms, library functions Characters and Strings.
BITS Pilani, Pilani Campus TA C252 Computer Programming - II Vikas Singh File Handling.
Chapter 3. Expressions and Interactivity CSC125 Introduction to C++
HTML Minute University Richard Fisher 10/1/2001 HTML FSA Training2 HTML Overview  HTML  HyperText Markup Language.
ES 314 Lecture 2 Sep 1 Summary of lecture 1: course overview intro to matlab sections of Chapters 2 and 3.
Chapter 5 Input and Output. What Is Input? What is input? p. 166 Fig. 5-1 Next  Input device is any hardware component used to enter data or instructions.
Bitmap Editing – Lesson 1
Processing Processing is a simple programming environment that was created to make it easier to develop visually oriented applications with an emphasis.
SET 19 PROGRAMMING THE MOUSE. Mouse Features All mouse operations within a program are performed by standard INT 33H functions of the form: MOV AX, function.
Polar Coordinates. Butterflies are among the most celebrated of all insects. Their symmetry can be explored with trigonometric functions and a system.
INTRODUCTION. Painting with numbers! Aspects Modeling Rendering Animation.
Chapter 6 Graphical User Interface (GUI) and Object-Oriented Design (OOD)
COMP 14: Files and Graphics for Applets June 19, 2000 Nick Vallidis.
Java Review Structure of a graphics program. Computer Graphics and User Interfaces Java is Object-Oriented A program uses objects to model the solution.
Graphics - setCoords. The coordinate system of Zelle graphics The default coordinate system for GraphWin is that the origin is in the upper left hand.
The printf Method The printf method is another way to format output. It is based on the printf function of the C language. System.out.printf(,,,..., );
Graphical Tree-Based Scientific Calculator: CalcuWiz Will Ryan Christian Braunlich.
Chapter 6: Graphical User Interface (GUI) and Object-Oriented Design (OOD) J ava P rogramming: Program Design Including Data Structures Program Design.
VARIABLES, TYPES, INPUT/OUTPUT, ASSIGNMENT OPERATION Shieu-Hong Lin MATH/CS Department Chapel.
MS Word Lesson Eight Formatting and Sorting Lists Mrs. Brown.
‘ {] Chapter 2 (HW01) Getting Started with Windows 7.
Copyright © 2013 Pearson Education, Inc. All rights reserved Section 1.1 The Distance and Midpoint Formulas; Graphing Utilities; Introduction to Graphing.
‘ {] PowerPoint Presentation to Accompany GO! with Windows 7 Getting Started Chapter 2 Getting Started with Windows 7.
Chapter 5: Data Input and Output Department of Computer Science Foundation Year Program Umm Alqura University, Makkah Computer Programming Skills
Computational Biology, Part E Basic Principles of Computer Graphics Robert F. Murphy Copyright  1996, 1999, 2000, All rights reserved.
Objectives Differentiate between raster scan display and random scan display.
1 Introduction Chapter 1 n What is Assembly Language? n Data Representation.
Computer Science 111 Fundamentals of Programming I Basic Program Elements.
1 Introduction to C# Programming Console applications No visual components Only text output Two types MS-DOS prompt - Used in Windows 95/98/ME Command.
Institute for Visualization and Perception Research 1 © Copyright 2000 Haim Levkowitz Introduction (Foley & Van Dam Ch 1) Uses of computer graphics … Some.
1 MatLab Basics Jae Hoon Kim Department of Physics Kangwon National University It contains hundreds of commands to do mathematics. Graph functions, solve.
How to start Visual Studio 2008 or 2010 (command-line program)
Introduction Computer Graphics & Its application Types of computer graphics Graphic display : random Scan & Raster Scan display Frame buffer and video.
Addison Wesley is an imprint of © 2010 Pearson Addison-Wesley. All rights reserved. Chapter 2 Graphics Programming with C++ and the Dark GDK Library Starting.
Computer Graphics Prepared By: Bahram Taheri Sept Amirkabir University of Technology & Birmingham University.
Introduction to Computer Graphics Chapter 6 – 2D Viewing Pt 1 1.
Digital Media Dr. Jim Rowan ITEC So far… We have compared bitmapped graphics and vector graphics We have discussed bitmapped images, some file formats.
GRAPHICS MODULE 14 STUDY BOOK. Graphic commands SCREEN - puts the screen into graphics mode WINDOW - allows scaling of the screen LINE - 3 formats –LINE.
Java Programming: From Problem Analysis to Program Design, 3e Chapter 6 Graphical User Interface (GUI) and Object-Oriented Design (OOD)
10H Interrupt. Option 0H – Sets video mode. Registers used: – AH = 0H – AL = Video Mode. 3H - CGA Color text of 80X25 7H - Monochrome text of 80X25 Ex:
Java Programming: From Problem Analysis to Program Design, Second Edition1 Lecture 5 Objectives  Learn about basic GUI components.  Explore how the GUI.
Arrays. The array data structure Array is a collection of elements, that have the same data type Integers (int) Floating point numbers (float, double)
Printing in Python. Printing Every program needs to do some output This is usually to the screen (shell window) Later we’ll see graphics windows and external.
INFORMATION SYSTEM – SOFTWARE TOPIC: GRAPHICAL USER INTERFACE.
Digital Media Lecture 5: Vector Graphics Georgia Gwinnett College School of Science and Technology Dr. Jim Rowan.
CS 115 Lecture 7 Graphics – coordinate systems, Text, Entry, aliases Taken from notes by Dr. Neil Moore.
PHP Overview. What is PHP Widely available scripting language Free Alternative to Microsoft’s ASP Runs on the Web Server; not in the browser Example:
Temple University Summer Research Progress: Week 2 – Extraction of Data George Fava Department of Electrical and Computer Engineering Temple University.
Lecture 2: 19/4/1435 Graphical algorithms Lecturer/ Kawther Abas CS- 375 Graphics and Human Computer Interaction.
1 Sections 5.1 – 5.2 Digital Image Processing Fundamentals of Java: AP Computer Science Essentials, 4th Edition Lambert / Osborne.
a graphical presentation of the five-number summary of data
Chapter 3 Syntax, Errors, and Debugging
2D Viewing Pipeline.
Polar Coordinates.
COPY ENGR.SABA MUGHAL FROM COMPUTER SYSTEMS DEPARTMENT
Discrete Math (2) Haiming Chen Associate Professor, PhD
Digital Media Dr. Jim Rowan ITEC 2110.
CSc 110, Spring 2018 Lecture 9: Parameters, Graphics and Random
Project 1: Into Space! CG Concepts Needed
Chapter 2 Graphics Programming with C++ and the Dark GDK Library
Terminal-Based Programs
Graphic and Other Object in Origin
Visualization by Use of The Graphic Package.
Presentation transcript:

1 Sung-Ju Kang Department of Physics Kangwon National University Basic Concept of The Computer Graphic. For the investigation of the physical problem by using the computer, the visualization of the solution are very advantageous for the researcher. The computer graphic is different to the real graphic, below text is the basic concept of the computer graphic. Contents 1. Graphic Card and Graphic Mode. 2. The Real Coordinate to The Computer Coordinate. 3. The Real Floating Point to The Pixel Integer Point. 4. Basic Graphic Functions.

2 1. Graphic Card and Graphic Mode. graphic cardGraphic driver HGAherc.bgi EGAega.bgi VGAegavga.bgi C language support the BGI (Borland Graphics Interface). Graphic driver of graphic card must exist in folder.

3 2. The Real Coordinate to The Computer Coordinate. The computer recognize the left upper edge as the origin, output images must be represented through the rectangular coordinate Real Coordinate: Windows Coordinate:......

4 3. The Real Floating Point to The Pixel Integer Point. Unit in the real world: Floating point number Unit in the computer graphic: Integer number transform int round(double U) { return(( U>0 ) ? (int) floor(U + 0.5) : (int) ceil(U - 0.5)); } floor find the largest integer not > U ceil find the smallest integer not < U ex) U = floor(U) = ceil(U) =

5 4. Basic Graphic Functions. Plot a point in the screen * putpixel(x,y,color) putpixel plots a pixel at a specified point. Plot to print a character String in the screen * outtextxy(x,y,s) outtextxy displays a string at the specified location. (graphics mode) Plot a line in the screen * line(x1,y1,x2,y2) line draws a line between two specified points.

6 Summary 1. C language support the BGI (Borland Graphics Interface). 2. We study the computer coordinate and the unit in the computer graphic. 3. We study the handling a point and a line in the screen.