ch6Graphucs Flashcards

(100 cards)

1
Q

What is clipping in computer graphics?

A

It’s the process of determining which parts of objects should be displayed and which should be discarded.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Why is clipping necessary?

A

To avoid rendering objects outside the viewing area and improve performance.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What does OpenGL do regarding clipping?

A

It performs clipping automatically, but understanding the process is important.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What are the main topics under clipping?

A

Windowing concepts, point clipping, line clipping, and polygon clipping.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is windowing?

A

Selecting a portion of a scene in world coordinates to display on the screen.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What are world coordinates?

A

Coordinates that define objects in the entire scene.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What defines the horizontal and vertical limits of the window?

A

wxmin, wxmax for horizontal; wymin, wymax for vertical.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What happens to objects outside the window?

A

They are clipped and not displayed.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Why do we use a clipping window?

A

To reduce computational cost and display only the visible portion of a scene.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is the condition for a point to be visible?

A

wxmin ≤ x ≤ wxmax and wymin ≤ y ≤ wymax.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What happens if a point doesn’t meet the condition?

A

It is clipped.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is line clipping?

A

Determining if a line is fully, partially, or not at all within a clipping window.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What if both endpoints of a line are inside the window?

A

The line is not clipped.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What if one endpoint is inside and the other is outside?

A

The line is partially clipped.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What if both endpoints are outside?

A

Further checks are needed to determine if it intersects the window.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is brute force line clipping?

A

A basic method of checking line visibility through boundary intersection calculations.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

What are the four window boundaries?

A

Left, right, top, bottom.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

Why is brute force clipping inefficient?

A

It requires many calculations, which are costly in large scenes.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

What does ‘TA’ stand for in brute force?

A

Trivially Accepted.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

What does ‘TR’ stand for in brute force?

A

Trivially Rejected.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

When is a line trivially accepted (TA)?

A

When both endpoints lie inside the clipping window.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

When is a line trivially rejected (TR)?

A

When both endpoints lie outside the same boundary.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

What happens if a line is neither TA nor TR?

A

Check for intersections with the window edges.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

What are the two outcomes for lines with both endpoints outside?

A

Discard if completely outside or clip if it intersects the window.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
Which mathematical concept helps find the intersection point?
The equation of the line.
26
If a line goes from (1,1) to (10,5), and window xmax=4, what part is visible?
From (1,1) to the intersection point at x=4.
27
What must be checked before accepting the intersection point?
If it lies within the segment's range.
28
Why can't we apply brute force to every line in large scenes?
It becomes too slow due to high computational cost.
29
What is the Cohen-Sutherland algorithm?
An efficient method for line clipping that reduces the number of intersection tests.
30
Who developed the Cohen-Sutherland algorithm?
Ivan Sutherland and an associate named Cohen.
31
How is the world space divided in this algorithm?
Into 9 regions using 4-bit region codes.
32
What does the region code 0000 represent?
The point is inside the window.
33
What does a region code like 1010 indicate?
The point is above and to the right of the window.
34
What operation is used to check rejection?
Bitwise AND of the two region codes.
35
What if both endpoints have region code 0000?
The line is trivially accepted.
36
What if the bitwise AND of two region codes ≠ 0?
The line is trivially rejected.
37
What if a line cannot be trivially accepted or rejected?
Find intersection points with the window boundaries.
38
What does labeling points mean in this algorithm?
Assigning 4-bit region codes to each endpoint.
39
What do the 4 bits represent in the region code?
Top, bottom, right, and left of the window.
40
What happens to a line from P9 (inside) to P10 (outside bottom)?
It's clipped at the bottom and partially drawn.
41
What happens to a line from P3 (left outside) to P4 (top outside)?
It is clipped and not drawn.
42
What happens to a line from P7 (below) to P8 (right)?
It is clipped at both ends and the visible portion is drawn.
43
How are intersection points calculated in this algorithm?
Based on which boundary the point is outside of.
44
What is the advantage of this algorithm?
Fewer intersection calculations and early rejection.
45
What does a 1 in a region code bit indicate?
That the point is outside the window in that direction.
46
When is intersection calculation necessary?
If both endpoints have different region codes but bitwise AND is zero.
47
Why use bitwise operations in clipping?
They are fast and efficient for testing.
48
Can we apply line clipping directly to polygons?
No, it would break the polygon into disjoint segments.
49
What is the requirement after polygon clipping?
The result must be a closed, connected polygon.
50
What does the Sutherland-Hodgman algorithm do?
Clips polygons by processing vertices against each boundary.
51
How are boundaries processed in Sutherland-Hodgman?
One at a time — left, right, bottom, top.
52
What happens after each boundary clip?
A new set of vertices is generated.
53
What is Case 1 in Sutherland-Hodgman?
First vertex outside, second inside → add intersection and second vertex.
54
What is Case 2 in Sutherland-Hodgman?
Both vertices inside → add second vertex.
55
What is Case 3 in Sutherland-Hodgman?
First vertex inside, second outside → add intersection only.
56
What is Case 4 in Sutherland-Hodgman?
Both vertices outside → add nothing.
57
What is the purpose of saving intersection points?
To form the new clipped polygon.
58
How many boundaries are checked in total?
Four.
59
Can this algorithm handle concave polygons well?
No, it may introduce extraneous lines.
60
What kind of polygons can Weiler-Atherton handle?
Concave polygons and polygons with holes.
61
What data structure is used in Weiler-Atherton?
Linked list.
62
What is the main idea of Weiler-Atherton?
Follow polygon boundary for inside entries, and window boundary for outside exits.
63
What are the two paths followed in Weiler-Atherton?
Polygon path and window boundary path.
64
What is the output of Weiler-Atherton?
One or more closed polygons.
65
What are the two types of clipping?
Line clipping and area (polygon) clipping.
66
What happens when only a portion of an object lies in the window?
That portion is kept, rest is clipped.
67
What is the goal of clipping algorithms?
Improve rendering efficiency and avoid drawing outside areas.
68
Which algorithm uses 4-bit region codes?
Cohen-Sutherland.
69
Which algorithm works by comparing edges against boundaries in turn?
Sutherland-Hodgman.
70
How do you find outcode bits for a point?
Compare its coordinates to the window boundaries.
71
In Cohen-Sutherland, what does it mean if both outcodes are zero?
The line is fully inside.
72
What if outcodes share a common bit (e.g., both top)?
The line is fully outside.
73
In Sutherland-Hodgman, what is output after processing all boundaries?
The final clipped polygon.
74
What is the clipping window defined by?
wxmin, wxmax, wymin, wymax.
75
What's the difference between windowing and clipping?
Windowing selects the visible region; clipping discards the non-visible parts.
76
What type of clipping can handle polygons with holes?
Weiler-Atherton.
77
What is scan conversion?
The process of converting primitives into pixels.
78
Which method is slower, brute force or Cohen-Sutherland?
Brute force.
79
Which polygon algorithm can introduce extra lines in concave shapes?
Sutherland-Hodgman.
80
Which clipping algorithm is suitable for real-time systems?
Cohen-Sutherland due to efficiency.
81
A point is clipped if it is __________ the window.
Outside.
82
__________ clipping is easier than line clipping.
Point.
83
A region code of 0001 means the point is __________ the window.
Below.
84
The brute force method calculates line __________.
Intersections.
85
Sutherland-Hodgman processes one __________ at a time.
Boundary.
86
A polygon must remain __________ after clipping.
Closed.
87
The Weiler-Atherton algorithm can output __________ polygons.
Multiple.
88
Region codes help to __________ lines quickly.
Accept or reject.
89
Lines outside the same region are __________ rejected.
Trivially.
90
The visible part of a line lies between P0 and __________.
The intersection point.
91
(T/F) Brute force is the most efficient clipping algorithm.
False.
92
(T/F) Cohen-Sutherland uses region codes to avoid unnecessary intersection tests.
True.
93
(T/F) Windowing changes object geometry.
False.
94
(T/F) Weiler-Atherton can be used for convex and concave polygons.
True.
95
(T/F) Sutherland-Hodgman is preferred for complex polygons with holes.
False.
96
(T/F) Clipping can affect performance in rendering.
True.
97
(T/F) Clipping should always be done manually in OpenGL.
False.
98
(T/F) Region codes have only two bits.
False.
99
(T/F) In Cohen-Sutherland, region code 0000 means the point is outside.
False.
100
(T/F) The top bit in the region code represents the point being above the window.
True.