Baking in the vertex colors

Assignment Help Basic Computer Science
Reference no: EM13701008

The project will test your skills in writing a simple interactive WebGL application that runs from a webpage and uses three.js. The basic outline of the project is as follows:
Part I
Write a function that takes in a size parameter and draws a sphere of that size.

  • Render a sphere with one directional light in the scene and use a material that uses diffuse as well as specular properties
  • The camera is fixed and the sphere location can be changed in the x or z directions using the arrow keys.
  • Pressing the + or - changes the size of the sphere (min 2 and max 8)
  • Pressing S makes the sphere flat shaded
  • Pressing G makes the sphere gouraud shaded
  • Pressing Q makes the sphere phong shaded

Part II
Render the sphere in Part I by baking in the vertex colors, for every vertex calculate its vertex normal by averaging the face normals. Normalize it and then pass the normalized value as a Hue Saturation and Lightness color value i.e. x -> H y->S and z->L
You can enable this feature by pressing B

Submitting instructions:
Create an html page that calls the .js file used for the project and submit both the files.

 

Reference no: EM13701008

Questions Cloud

Prepare the report requested by mrs. daycon : Daycon' president felt that with an aggressive marketing campaign, relocation of some of the locations and with a new corporate name, BL should be able to rebound and return to a profitable position by the end of the year.
Ap is the amount of autonomous planned : Where Y is real GDP, Ap is the amount of autonomous planned spending that is independent of the interest rate, Ms is the nominal supply, P is the price level, and W is the nominal wage rate. Assume that Ap equals 5,000, Ms equals 2,000, W equal..
Architecture to assist in the decision-making process : Using enterprise architecture to assist in the decision-making process, write a 1500 words paper in which you do the following:Determine activities that you believe would be appropriate for outsourcing.
Secure data access and encryption of a patientdatabase : OverviewIn this lab, you implemented policies that map to the Sarbanes-Oxley Act (SOX), the PaymentCard Industry Data Security Standard (PCI-DSS), and the Health Insurance Portability andAccountability Act (HIPAA). You ensured secure data acce..
Baking in the vertex colors : Render the sphere in Part I by baking in the vertex colors, for every vertex calculate its vertex normal by averaging the face normals. Normalize it and then pass the normalized value as a Hue Saturation and Lightness color value i.e. x -> H y-..
Profession might be held liable for negligence : The paper should be 5 to 7 typed pages. Professional Liability-select an allied health (nonphysician) profession; this can be your own profession or another profession that interests you. Some examples of allied health professions include phys..
An anonymous block to include two sql statements coded : Write a script that uses an anonymous block to include two SQL statements coded as a transaction to delete the row with a customer ID of 8 from the Customers table. To do this, you must first delete all addresses for that order from the Address..
Public key cryptography : Write a paper about "Public Key Cryptography".The paper will be at least 1,250 words in length. APA formatting must be used, along with proper citations in APA format. At least seven (7) reputable sources will be cited, and at least three (3) o..
Compute the capability indices for both firms : An appliance manufacturer wants to contract with a repair shop to handle authorized repairs in Indianapolis - Compute the capability indices for both firms.

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Which operation following expression will be performed first

Which operation in the following expression will be performed first? c = a++ / b + 5;

  The area of a circle is pi multiplied by the square

The area of a circle is pi multiplied by the square of the radius

  In what ways do the experts foresee the use

Review the literature and analyze the strengths and weaknesses of both virtualization and cloud computing in providing secure and trusted systems.

  Print the list after each value is inserted into the list

Generate 10 random numbers between in the range of 25 to 50. Insert them into a list, keeping the list in order as each value is inserted. Print the list after each value is inserted into the list.

  Show how the value ascii miriam is stored in memory

Show how the value ASCII "MIRIAM" is stored in memory in Big Endian format starting at location 100 hexadecimal. Assume that each memory location stored two ASCII characters.

  Generate a set of input test values

Generate a set of input test values.

  Two problems in lisp

1. Define a function foo(A,L), where A is an integer and L is a list that will remove each A in L. This is a shallow function.

  Describe the same task using intelligent software agents

Describe the same task using intelligent software agents

  Use electronic marketing resources-company-s stockholders

Your company can only afford to utilize three electronic marketing resources to accomplish these goals. Select three electronic marketing resources to use and justify each resource in memo to company's stockholders.

  Explain why its difficult to support direct assess to files

explain why its difficult to support direct assess to files with variable length records. suggest a method for handling this type of file if direct access is required.

  Write program determines for each sales person their salary

This must be written in C++. A company pays its salespeople on a commission basis. The salespeople each receive $200 per week plus a 9 percent commission of their gross sales for the sales period.

  Write a paragraph about each topology

Write a paper detailing the advantages and disadvantages of the three main topologies: Ring, Bus, and Star.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd