Computer Graphics Prof. Muhammad Saeed Dept. of Computer Science & IT Federal Urdu University of Arts, Sciences and Technology.

Slides:



Advertisements
Similar presentations
Computer Graphics Prof. Muhammad Saeed Dept. of Computer Science & IT
Advertisements

Computer Graphics Prof. Muhammad Saeed Dept. of Computer Science & IT Federal Urdu University of Arts, Sciences and Technology.
Computer Graphics Prof. Muhammad Saeed Dept. of Computer Science & IT Federal Urdu University of Arts, Sciences and Technology.
Computer Graphics Prof. Muhammad Saeed Dept. of Computer Science & IT Federal Urdu University of Arts, Sciences and Technology.
Computer Graphics Prof. Muhammad Saeed Dept. of Computer Science & IT
Microsoft® Small Basic
IT300: Introduction to Computer Graphics
CS 450: COMPUTER GRAPHICS DRAWING ELLIPSES AND OTHER CURVES SPRING 2015 DR. MICHAEL J. REALE.
Chapter 9 Color, Sound and Graphics
COMPUTER PROGRAMMING I Objective 8.03 Apply Animation and Graphic Methods in a Windows Form (4%)
Computer Graphics Tz-Huan Huang National Taiwan University (Slides are based on Prof. Chen’s)
Computer Graphics Lecture 4 Geometry & Transformations.
Introduction to InDesign Understanding the Basics DTB203 Interior Visualisation
1 Geometrical Transformation 2 Outline General Transform 3D Objects Quaternion & 3D Track Ball.
Graphics and Multimedia. Outline Introduction Graphics Contexts and Graphics Objects Color Control.
Four simple expressions in meta. Data objects Pieces of data in a computer are called objects Today, we’ll talk about four kinds of objects Numbers Pictures.
® Microsoft Office 2010 PowerPoint Tutorial 2: Adding and Modifying Text and Graphic Objects.
Syracuse University 3D Framework using GDI+.Net Carmen Vaca Ruiz Independent Study Fall 2004 Instructor: Dr. Jim Fawcett.
April Geometric Transformations for Computer Graphics Shmuel Wimer Bar Ilan Univ., School of Engineering.
Graphics and Multimedia. Introduction The language contains many sophisticated drawing capabilities as part of namespace System.Drawing and the other.
Graphics Images – PictureBox control Drawing graphics - Graphics object Multimedia controls PictureBox control Image property – select image Choose how.
Computer Graphics Prof. Muhammad Saeed. Drawing and Transformation of Figures in C# August 1,
1 Chapter 26 D&D – Graphics Outline 26.1 Introduction 26.3 Graphics Contexts and Graphics Objects 26.4 Color Control 26.5 Font Control 26.6 Drawing Lines,
Graphics Standard Grade Computing. Graphics Package n A graphics package is another General Purpose Package. n It is used to draw pictures on the monitor.
CS324e - Elements of Graphics and Visualization Java2D Graphics.
ICS 61 - Graphics. Light Color Wheel Color Perception.
Lecture Set 13 Drawing Mouse and Keyboard Events Part A - Drawing.
CST238 Week 5 Questions / Concerns? Announcements – HW#1 due (Project ideas) – Check-off Take Home lab#4 Recap New topics – Drawing Coming up: – GUI Bloopers.
CS 450: COMPUTER GRAPHICS REVIEW: DRAWING ELLIPSES AND OTHER CURVES SPRING 2015 DR. MICHAEL J. REALE.
Object Oriented Programming Graphics and Multimedia Dr. Mike Spann
2D Graphics: Rendering Details
ETD 1330 CAD Introduction to AutoCAD Features Professor: Dr. Miguel Alonso Jr. Fall 2008.
Introduction to Flash. Topics What is Flash? What can you do with it? Simple animation Complex interactive web application, such as an online store. Starting.
1 CS 430/536 Computer Graphics I 3D Transformations World Window to Viewport Transformation Week 2, Lecture 4 David Breen, William Regli and Maxim Peysakhov.
Introduction & Installation. What is GeoGebra? GeoGebra is a Dynamic Mathematics Software (DMS) for teaching and learning mathematics from middle school.
Tutorial 2 Drawing Shapes, Adding Text, and Creating Symbols.
BIM211 – Visual Programming Interacting with Users Graphics 1.
Geometric Transformations Hearn & Baker Chapter 5 Some slides are taken from Robert Thomsons notes.
UW EXTENSION CERTIFICATE PROGRAM IN GAME DEVELOPMENT 2 ND QUARTER: ADVANCED GRAPHICS Math Review.
Subject Name: Computer Graphics Subject Code: Textbook: “Computer Graphics”, C Version By Hearn and Baker Credits: 6 1.
CS COMPUTER GRAPHICS LABORATORY. LIST OF EXPERIMENTS 1.Implementation of Bresenhams Algorithm – Line, Circle, Ellipse. 2.Implementation of Line,
CISC 110 Day 3 Introduction to Computer Graphics.
Images Part 11 dbg. 2 Images The form and several controls can display a number of different types of image files in the BackgroundImage Property. These.
GORT: Specifications Leon Kania – Haipin Cua – Thoren McDole – Chang Huang.
CS559: Computer Graphics Lecture 9: 3D Transformation and Projection Li Zhang Spring 2010 Most slides borrowed from Yungyu ChuangYungyu Chuang.
Computer Graphics I, Fall 2010 Transformations.
1 Teaching Innovation - Entrepreneurial - Global The Centre for Technology enabled Teaching & Learning, N Y S S, India DTEL DTEL (Department for Technology.
1 Introduction to Computer Graphics with WebGL Ed Angel Professor Emeritus of Computer Science Founding Director, Arts, Research, Technology and Science.
Modeling Transformations Mario Costa Sousa University of Calgary CPSC 453, Fall 2001 Mario Costa Sousa University of Calgary CPSC 453, Fall 2001.
COMPUTER GRAPHICS AND LINEAR ALGEBRA AN INTRODUCTION.
Lecture 10 Geometric Transformations In 3D(Three- Dimensional)
Geometric Transformations Hearn & Baker Chapter 5
Graphics and Multimedia
Microsoft® Small Basic
Drawing Mouse and Keyboard Events Part A - Drawing
FALL into Math Quadrant II Quadrant I Quadrant III Quadrant IV
ThS. Nguyễn Hà Giang Khoa CNTT - Hutech
CASE Tools Graphical User Interface Programming Using C#
A movement of a figure in a plane.
A movement of a figure in a plane.
Introduction to Computer Graphics
Geometric Transformations for Computer Graphics
In this chapter, you will learn the following:
Algebraic Representations of Transformations
Object Oriented Programming
Transformations.
Chapter 12 Graphics in Windows and the Web
Introduction to Computer Graphics with WebGL
CPT 450 Computer Graphics 3rd Lecture.
In this chapter, you will learn the following:
Presentation transcript:

Computer Graphics Prof. Muhammad Saeed Dept. of Computer Science & IT Federal Urdu University of Arts, Sciences and Technology

Drawing and Transformation of Figures in C#

FUUASTDept. of Comp. Sc.& IT3 1. Basic Mathematics 1.Matrices i.Addition ii.Multiplication iii.Transpose iv. Inverse v.Algebraic Laws vi.Symmetric and Orthogonal 2.Geometry i.Coordinate systems ii. Introduction to 2D and 3D geometry iii.Basic trigonometric Formulae Transformation of Figures Computer Graphics

FUUASTDept. of Comp. Sc.& IT4 2. Transformations 1.Rotation i.Rotation matrices for 2D and 3D systems ii.Homogeneous coordinates iii.Rotation around any axis, Quaternions iv.Compound rotation, inverse rotation v.Orthogonality 2.Translation i.Translation matrices for 2D and 3D systems ii. Compound translations and rotations, inverse translation 3.Scaling i.Scaling matrix and its inverse ii.Compound scaling with other transformations Transformation of Figures Computer Graphics

FUUASTDept. of Comp. Sc.& IT5 4.Reflection i.Reflection matrices for 2D in axes and lines ii.Reflection in planes iii.Inverse reflection 5.Inversion i.Through the origin for 2D and 3D systems ii. Inverse inversion 6.Shearing Shearing a 3D figure 7.Representing 3D on 2D An approximate representation Transformation of Figures Computer Graphics

FUUASTDept. of Comp. Sc.& IT6 3.Programming in C# ……….. 1.C# GDI+ Introduction 2. Drawing Primitives i.Graphics class, color, pen, brush private void Form1_Paint(object sender, PaintEventArgs e) { Graphics g = e.Graphics; Pen pen = new Pen(Color.Blue, sizeOfPen); //Pen pen = new Pen(Color.FromArgb(red, green, blue)); Brush brush = new SolidBrush(Color.FromArgb(red, green, blue)); Point point = new Point(); Brush brush1=Brushes.DarkSeaGreen; } public void userDefinedFunction() { Graphics g = CreateGraphics(); } Transformation of Figures Computer Graphics

FUUASTDept. of Comp. Sc.& IT7 Transformation of Figures Computer Graphics ii.Line, circle, ellipse, rectangle, filled figures g.DrawLine(pen, x1,y1,x2,y2); g.DrawEllipse(pen, x1, y1, width, height); g.DrawRectangle(pen, x1, y1 width, height); g.FillEllipse(brush, x1, y1, width, height); iiiColor Common Dialog Box ColorDialog dlg = new ColorDialog(); dlg.FullOpen = true; Brush brush1; if (dlg.ShowDialog() == DialogResult.OK) { brush1 = new SolidBrush(dlg.Color); g.FillRectangle(brush1, x1, x2, width, height); } 3.Controls and Event Handling Menu Text Box, Label Button, Check Box, Radio Button Group Box Mouse & keyboard event handling

FUUASTDept. of Comp. Sc.& IT8 4.Transformations i.2D graphics, rotation, translation, scaling, reflection, inversion and shearing ii.Representing 3D on 2D iii.3D transformations of a wireframe object such acube 5.Lines and curves i.parametric and implicit equations of lines, curves and conics in 2D system. ( List given) ii.Bezier Curves and their properties 6.Morphing ( Tweening) i. introduction. ii. a simple 2D shape e.g. H to a house drawing 7.Clipping i.Cohen-Sutherland Algorithm ii.Cyrus-Beck Algorithm Transformation of Figures Computer Graphics

FUUASTDept. of Comp. Sc.& IT9 Transformation of Figures Computer Graphics 8. Advanced Features of C# i.2D transforms using System.Drawing.2D RotateTransform(angle) TranslateTransform(x-increment,y-increment) ScaleTransform(x-Factor, y-Factor) ResetTransform() ii.Image and Bitmap classes Image image = Image.FromFile(file Name) g.DrawImage(image,x,y,image.Width, image.Height) image.Save(File Name, imageFormat) Bitmap bitmap = new Bitmap(File Name) bitmap = (Bitmap)Bitmap.FromFile(File Name) Color color = bitmap.GetPixel(x,y) bitmap.SetPixel(x,y,color) bitmap.Save (File Name, imageFormat) //ImageFormat.Png 9.Introducing Fractals i.Definition & Types ( slides )slides ii.Examples( Slides One, Two, Three )OneTwoThree

FUUASTDept. of Comp. Sc.& IT10 The End Transformation of Figures Computer Graphics