CSC214 · TU past paper
Computer Graphics 2075 question paper
The complete TU 2075 exam paper for Computer Graphics (CSC214), all 12 questions with solved model answers written to the mark scheme.
Tap a question to open its answer.
- 110 marksNumericalClippingHideAnswer
Define window, viewport and viewing transformation. Let ABCD be the regular window with A(20, 20), B(90, 20), C(90, 70), and D(20, 70). Find the region codes for end points and use Cohen Sutherland algorithm to clip the lines P(10, 30) Q(80, 90).[10]
Window, Viewport, Viewing Transformation and Cohen-Sutherland Clipping
Part 1: Definitions
Window: A rectangular region defined in the world coordinate system that selects the portion of a scene to be displayed. Only objects lying inside the window are shown.
Viewport: A rectangular region on the display device (screen, in device/normalized coordinates) onto which the contents of the window are mapped.
Viewing Transformation: The mapping of the contents of a window in world coordinates to a viewport on the display device, also called the window-to-viewport transformation. Composite form:
$$T_{wv} = T(xv_{min}, yv_{min}) \cdot S(S_x, S_y) \cdot T(-xw_{min}, -yw_{min})$$
$$S_x = \frac{xv_{max}-xv_{min}}{xw_{max}-xw_{min}}, \qquad S_y = \frac{yv_{max}-yv_{min}}{yw_{max}-yw_{min}}$$
Part 2: Cohen-Sutherland Line Clipping
Given Data
Window ABCD: A(20,20), B(90,20), C(90,70), D(20,70)
$$x_{min}=20,\quad x_{max}=90,\quad y_{min}=20,\quad y_{max}=70$$
Line: $P(10,30)$ to $Q(80,90)$
Region Code (Top | Bottom | Right | Left)
P(10, 30):
- Top: $30>70$? No → 0
- Bottom: $30<20$? No → 0
- Right: $10>90$? No → 0
- Left: $10<20$? Yes → 1
$$\text{Code}(P) = 0001$$
Q(80, 90):
- Top: $90>70$? Yes → 1
- Bottom: $90<20$? No → 0
- Right: $80>90$? No → 0
- Left: $80<20$? No → 0
$$\text{Code}(Q) = 1000$$
Trivial Tests
- AND: $0001 \text{ AND } 1000 = 0000$ → not trivially rejected
- OR: $0001 \text{ OR } 1000 = 1001 \ne 0000$ → not trivially accepted
Line must be clipped. Slope quantities: $$\Delta x = 80-10 = 70, \qquad \Delta y = 90-30 = 60$$ $$m = \frac{\Delta y}{\Delta x} = \frac{60}{70} = \frac{6}{7}$$
Clip Point P (code 0001, Left boundary x = 20)
$$y = y_1 + m(x_{min}-x_1) = 30 + \frac{6}{7}(20-10) = 30 + \frac{60}{7} = 38.57$$
New point $P' = (20, 38.57)$
Code of $P'(20, 38.57)$: Top no, Bottom no, Right no, Left ($20<20$? no) → 0000 (inside)
Clip Point Q (code 1000, Top boundary y = 70)
$$x = x_1 + \frac{1}{m}(y_{max}-y_1) = 10 + \frac{7}{6}(70-30) = 10 + \frac{7}{6}\times 40$$ $$x = 10 + 46.67 = 56.67$$
New point $Q' = (56.67, 70)$
Code of $Q'(56.67, 70)$: Top ($70>70$? no) → 0, Bottom no, Right ($56.67>90$? no) → 0, Left no → 0000 (inside)
Final Result
Both endpoints now have code 0000 → line accepted.
$$\boxed{\text{Clipped line: } P'(20,\ 38.57) \text{ to } Q'(56.67,\ 70)}$$
The complete result requires clipping $Q$ as well, giving $Q'(56.67, 70)$.
- 210 marksBSP tree Method, Octree and Ray TracingHideAnswer
List any two disadvantages of BSP tree method in visible surface detection. Make a comparison between Painter’s algorithm and A-Buffer algorithm.[10]
--- Based on the properties of BSP trees in visible surface detection: 1. High Preprocessing Cost / Complex Tree Construction: The BSP tree must be built before rendering begins. Constructing the tree requires selecting partitioning plan...
- 310 marksSweep, Boundary and Spatial-Partitioning RHideAnswer
Describe the architecture of raster scan display. Explain about sweep, octree and boundary representations for solid modeling.[10]
--- In a raster scan system, the electron beam is swept across the screen one row at a time, from top to bottom. As the beam moves across each row, its intensity is turned on and off to create a pattern of illuminated spots. The picture ...
- 45 marksIntroduction, Callback functions, Color coHideAnswer
Give some basic color model. Give the basic command to draw the pixel and polygon in OpenGL. [5]
Color models are mathematical systems for describing colors using numerical values. The basic color models are: - An additive color model used in display devices (monitors, screens). - Colors are formed by combining red, green, and blue ...
- 55 marksNumericalScan Converting a Point and a straight LinHideAnswer
Trace the Bresenham’s Line drawing algorithm for the end points(1, 1) and (8, 5). [5]
- Start point: $(x1, y1) = (1, 1)$ - End point: $(x2, y2) = (8, 5)$ $$\Delta x = x2 - x1 = 8 - 1 = 7$$ $$\Delta y = y2 - y1 = 5 - 1 = 4$$ Since $\Delta x \Delta y$, we step along the x-axis (increment x by 1 each step). Initial decision ...
- 65 marksThree-Dimensional translation, Rotation, SHideAnswer
Derive the relation for three-dimensional translation and rotation. [5]
--- Translation moves a point linearly in space. Let point P(x, y, z) be translated by translation vector T(tx, ty, tz) to produce image point P'(x', y', z'). The translated coordinates are obtained by adding the translation distances to...
- 75 marksWireframe RepresentationHideAnswer
What is the purpose of wireframe representation? Describe about boundary and space partitioning. [5]
A wireframe model represents a 3D object by describing only its edges and vertices (corners). It is the simplest form of 3D object representation. Purposes: - To provide a quick and simple visual outline of a 3D object using only its edg...
- 85 marksNumericalScan Converting Circle and EllipseHideAnswer
Plot the ellipse centered at (0, 0) with radius rx = 8 and ry = 6, using mid point ellipse drawing algorithm. [5]
--- - Center $(xc, yc) = (0, 0)$ - $rx = 8$ - $ry = 6$ Precomputed: - $rx^2 = 64$ - $ry^2 = 36$ - Starting point: $(x0, y0) = (0, ry) = (0, 6)$ --- Continue while $2 ry^2 x < 2 rx^2 y$. Initial decision parameter: $$p10 = ry^2 - rx^2 ry ...
- 95 marksClippingHideAnswer
Define clipping. Discuss about cubic spline Interpolation. [5]
--- Clipping is a graphics operation that removes or cuts away portions of graphical objects (lines, polygons, curves, or text) that lie outside a defined viewing region or window. Only the portions of objects that fall within the clippi...
- 105 marksIntensity attenuation and Color consideratHideAnswer
How can we detect shadows in computer graphics? List the challenged in computing light model. [5]
--- Shadows help create realism in a scene. They allow humans to distinguish movement and depth of objects more clearly. Several techniques are used to create and detect shadows: - A shadow volume is a 3D region of space that is in shado...
- 115 marksRepresenting CurvesHideAnswer
Mention any two color command in OpenGL. Explain about Hermite curve. [5]
--- OpenGL provides color commands primarily in RGBA mode, where colors are specified using Red, Green, Blue, and optionally Alpha (transparency) components mapped onto the range (0.0, 1.0). This command specifies a color using three flo...
- 125 marksApplication of VRHideAnswer
List some applications of VR. What might be the possible navigation techniques and manipulating interfaces in virtual reality? Justify. [5]
Virtual Reality creates an entirely immersive virtual world where it becomes hard to differentiate between what is real and what is not real (typically achieved by wearing a helmet or goggles with VR technology). Its major applications i...