OBJ File Format 2005/10/03. CAIG Lab,NCTU2 OBJ File Format A text file format First character of each line specifies the type of command #: just some.

Slides:



Advertisements
Similar presentations
For(int i = 1; i
Advertisements

1 Building Models. 2 Objectives Introduce simple data structures for building polygonal models ­Vertex lists ­Edge lists OpenGL vertex arrays.
3D Game Programming Geometric Transformations
Section 6.2 Angles of Polygons.
2IV60 Computer graphics Graphics primitives and attributes Jack van Wijk TU/e.
Meshes Dr. Scott Schaefer. 3D Surfaces Vertex Table.
CSE325 Computer Science and Sculpture Prof. George Hart.
A Taste of Virtual Environment Development - SVE Amy Ulinski Raj Inugala.
1 Key Concepts:  Why C?  Life Cycle Of a C program,  What is a computer program?  A program statement?  Basic parts of a C program,  Printf() function?
PA1 Supplementary notes 1 Programming assignment You need to implement the following: 1. Display basic mesh Information Find the number of vertices, edges,
Geometric Objects and Transformations Geometric Entities Representation vs. Reference System Geometric ADT (Abstract Data Types)
3D Concepts Coordinate Systems Coordinates specify points in space 3D coords commonly use X, Y, & Z A vertex is a 'corner' of an object Different coordinate.
1 X file & Mesh Chapter 8. 2 What is X file? 1.X file is a file that is used to store D3D program's data. 2.Any X file has extension *.x. 3.X file could.
Zhang & Liang, Computer Graphics Using Java 2D and 3D (c) 2007 Pearson Education, Inc. All rights reserved. 1 Chapter 6 Graphics Contents.
CS-321 Dr. Mark L. Hornick 1 3-D Object Modeling.
In the name of God Computer Graphics Modeling1. Today Introduction Modeling Polygon.
Polygon Lists & 3-D File Formats Glenn G. Chappell U. of Alaska Fairbanks CS 481/681 Lecture Notes Monday, February 18, 2002.
CS 4363/6353 OTHER THINGS YOU SHOULD KNOW. OVERVIEW Matrix Stacks Raytracing and NPR Physics Engines Common File Formats.
Vertex – A point at which two or more edges meet Edge – A line segment at which two faces intersect Face – A flat surface Vertices, Edges, Faces.
COLLEGE OF ENGINEERING UNIVERSITY OF PORTO COMPUTER GRAPHICS AND INTERFACES / GRAPHICS SYSTEMS JGB / AAS 1 Shading (Shading) & Smooth Shading Graphics.
Warm Up Week 1. Section 6.1 Day 1 I will identify, name, and describe polygons. Ex 1 PolygonHas three or more sides that connect at endpoints.
Image Synthesis Rabie A. Ramadan, PhD 1. 2 About my self Rabie A. Ramadan My website and publications
Game Programming 06 The Rendering Engine
Homework Helpers. Content OFF files STL: vector, algorithm Model loaders: OBJ, 3DS.
Computer Graphics Basic 3D Geometry CO2409 Computer Graphics Week 5-1.
Introduction to OpenGL. OpenGL is a low-level graphics library specification. It makes available to the programmer  a small set of geometric primitives.
CS418 Computer Graphics John C. Hart
Vertices, Edges and Faces By Jordan Diamond. Vertices In geometry, a vertices is a special kind of point which describes the corners or intersections.
RENDERING Introduction to Shading models – Flat and Smooth shading – Adding texture to faces – Adding shadows of objects – Building a camera in a program.
Bump Map 1. High Field Function: H(u, v) New Normal : N’
3D Objects in WebGL Loading 3D model files. Announcement Midterm exam on 12/2 –No Internet connection. –Example code and exam questions will be on USB.
Do Now. Section 8.2 Angles in Polygons Polygon Interior Angles Theorem The sum of the measures of the interior angles of a convex polygon with n sides.
Introduction to Meshes Lecture 22 Mon, Oct 20, 2003.
Computer Graphics I, Fall 2010 Building Models.
Textures – Basic Principles Lecture 29 Fri, Nov 14, 2003.
Ch 1.6 CLASSIFY POLYGONS. In this section we will… Look at what makes something a polygon. Identify polygons by their sides and angles Identify polygons.
Graphics Graphics Korea University kucg.korea.ac.kr Geometric Primitives 고려대학교 컴퓨터 그래픽스 연구실.
OpenGL CS418 Computer Graphics John C. Hart. OpenGL Based on GL (graphics library) by Silicon Graphics Inc. (SGI) Advantages: Runs on everything, including.
OpenGL CS418 Computer Graphics John C. Hart. OpenGL: Event-driven How in OpenGL? Programmer registers callback functions Callback function called when.
4. Geometric Objects and Transformations

Angel: Interactive Computer Graphics 5E © Addison-Wesley 2009
2.6 Solving Systems of Linear Inequalities
Objects aka Polygonal Mesh (6.2)
Types of Polygons Polygon- a flat closed figure made of straight line segments Circle the figures that are polygons. Cross out the figures 
that are.
Chapter 2 part #1 C++ Program Structure
Building Models Ed Angel
Lesson 5-4 Coordinate Geometry
Isaac Gang University of Mary Hardin-Baylor
Meshes.
Computing Vertex Normals from Arbitrary Meshes
TITLE TITLE TITLE TITLE
Geometric and Intelligent Computing Laboratory
Angel: Interactive Computer Graphics5E © Addison-Wesley 2009
Introduction to Meshes
Color and Shading Lecture 9 Mon, Sep 26, 2005.
Motion in Space: Velocity and Acceleration
Computer Graphics 5Practical Lesson
Notes Over 5.1 Graphing a Quadratic Function Vertex: Up Normal.
I have 4 faces. I have 6 edges. I have 4 vertices.
2. Coordinates.
Warm up Graph 1. y = 3x² - 6x y = -x² + 2x – 1
Lecture 04: Data Representation (II)
Polygons.
Introduction to Meshes
Opengl implementation
Presentation transcript:

OBJ File Format 2005/10/03

CAIG Lab,NCTU2 OBJ File Format A text file format First character of each line specifies the type of command #: just some comment ex: # 1760 vertices v: vertex ’ s geometric position (float) ex: v

CAIG Lab,NCTU3 OBJ File Format (Cont.) vt: texture coordinate (float from 0~1) ex: vt vn: normal vector (float) ex: vn f: polygonal face (int) f int int int … f int/int int/int int/int …

CAIG Lab,NCTU4 OBJ File Format (Cont.) f int/int/int int/int/int … ex: f f 1/1/1 2/2/2 3/3/3 4/4/4 f 1//1 2//2 3//3 4//4 Must be flat and convex

CAIG Lab,NCTU5 OBJ File Format (Cont.) g: group name ex: g body usemtl: name a material to use ex: usemtl black s: group number ex: s 4