Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1. Plot the contour of the function = (2 + 2 1)3 2 3 using GL_POINTS. You will need to write the code in myDisplay

1. Plot the contour of the function = (2 + 2 1)3 2 3 using GL_POINTS. You will need to write the code in myDisplay function. Remember that the screen size is width = 640 and height = 480. a. Using a nested loop for [2.0,2.0] and y [2.0,2.0], with the step size of 0.01 for both x and y, calculate the value = (2 + 2 1)3 2 3. b. For the values of [1.0,0.0] plot the point (x, y) in red. c. For any other value of z plot the point (x, y) in color (0, 0.5, 0.5). d. The point size will be 4.0. Do not forget to scale and translate x and y coordinates so that they are mapped correctly to the screen. e. You should not use gluOrtho2D() and glViewport() for automatic scaling and translation, rather calculate the scaling and translation parameters manually. Your program should result in a plot like this (5 Points):

a. Using a nested loop for [2.0,2.0] and y [2.0,2.0], with the step size of 0.01 for both x and y, calculate the value = (2 + 2 1)3 2 3.

b. For the values of [1.0,0.0] plot the point (x, y) in red.

c. For any other value of z plot the point (x, y) in color (0, 0.5, 0.5).

d. The point size will be 4.0. Do not forget to scale and translate x and y coordinates so that they are mapped correctly to the screen.

e. You should not use gluOrtho2D() and glViewport() for automatic scaling and translation, rather calculate the scaling and translation parameters manually.

USING Visual studio C++

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Semantics Of A Networked World Semantics For Grid Databases First International Ifip Conference Icsnw 2004 Paris France June 2004 Revised Selected Papers Lncs 3226

Authors: Mokrane Bouzeghoub ,Carole Goble ,Vipul Kashyap ,Stefano Spaccapietra

2004 Edition

3540236090, 978-3540236092

More Books

Students also viewed these Databases questions

Question

an element of formality in the workplace between different levels;

Answered: 1 week ago