How do we choose which object to show, given a specific pixel?
A. Z-buffer, as in OpenGL.
B. We sort the objects by their Z value.
C. We shoot rays into the scene, and average the contribution of each.
D. We use the closest intersection of the ray shot into the scene.
查看答案
Can we conceivably change the shape of an object using a texture?
A. Yes. We can change the location of every fragment using the fragment shader.
B. Yes. We can change the location of every vertex using the vertex shader.
C. No. Textures are images and cannot be used for non-color values.
D. No. We can load textures in the fragment shader, but not the vertex shader.
By updating the position in every draw call, will the speed of the animation be consistent?
A. Yes. This program will run at equal frames per second across any platform.
B. Yes. The draw call will be called at a rate independent of the displayed frames per second of our program.
C. No. However, the draw call will be at a consistent rate on a specific system.
D. No. The speed at which the draw function is called is not consistent, even within a specific system.
Imagine if instead of calling glDepthFunc(GL_LESS);, we call glDepthFunc(GL_ALWAYS);. This means that each incoming pixel value will always be considered "in front" of the old value in the Z-buffer.In this scheme, does the order in which we draw objects matter, even though we are using a Z-buffer?
A. Yes
B. No
What do shaders know about matrix stacks?
A. Shaders do not know anything about matrix stacks.
B. Shaders only know how to fetch the top matrix of the matrix stack.
C. The entire stack data structure is sent to the shader programs.
D. Shaders reference the stack data structure on the host CPU program.