Difference between revisions of "Project4W21"

From Immersive Visualization Lab Wiki
Jump to: navigation, search
(Extra Credit (10 Points))
(Components)
Line 43: Line 43:
 
* The ability to move the blocks around with the controller, including putting them on top of one another.
 
* The ability to move the blocks around with the controller, including putting them on top of one another.
  
==Components==
+
==Components (100 Points)==
  
 
* Create a large rectangle to serve as a '''table surface''' to put the building blocks on. Place it at the height of a typical desk and right in front of the user in the VR space.
 
* Create a large rectangle to serve as a '''table surface''' to put the building blocks on. Place it at the height of a typical desk and right in front of the user in the VR space.

Revision as of 12:21, 2 March 2021

Contents

Homework Assignment 4: Building Blocks

Prerequisites:

  • Windows or Mac PC
  • Unity
  • GitHub Repo (accept from GitHub Classroom link)
  • VR headset with two 3D-tracked controllers, such as the Oculus Quest 2, Rift (S), Vive, etc.

Learning objectives:

  • 3D menu interaction
  • Radial and rectangular menus
  • Hand-centered menus
  • Room-centered menus
  • Menu widgets: buttons, sliders, dials

For this assignment you can obtain 100 points, plus up to 10 points of extra credit.

The goal of this assignment is to create a 3D application to create building blocks of different shapes and colors and allow the user to play with them.

All interaction (except otherwise noted) has to be done with the VR system (headset and controllers). The user is not allowed to use keyboard or mouse.

We will give an introduction to this project in discussion on Monday, February 22nd at 4pm.

This project was inspired by the following things:

  • A Wood Blocks childrens' toy:

Building-Blocks.jpg

Concept

Create an application to allow the user to spawn 3D building blocks with a 3D menu and build structures with the blocks. Gravity should be part of your application. The user is assumed to be in a seated position when the application starts, as well as throughout the application.

Implement the following features:

  • A radial menu to select the type of block to create.
  • A stationary menu on the desk to change color and size of an object, as well as control gravity.
  • The ability to move the blocks around with the controller, including putting them on top of one another.

Components (100 Points)

  • Create a large rectangle to serve as a table surface to put the building blocks on. Place it at the height of a typical desk and right in front of the user in the VR space.
  • Use the Virtual Hand interaction method for all interactions with the application. You can re-use the one from project 3.

Radial Menu

Create a radial menu that shows up next to your non-dominant hand's controller

  • This menu should be about 20cm wide.
  • It should be anchored to your non-dominant hand, i.e., move with that hand.
  • It should show up when the user twists their wrist so that the palm faces towards the user. It should be hidden otherwise. Tune your parameters for showing the menu so that it shows up reliably when you want it to and won't when you don't.
  • When the radial menu is visible, the user can click on an item with the dominant hand's controller.
  • The radial menu should have entries for the four different shapes the user can create: cubes, cuboids, spheres and cylinders. (All are part of Unity's built-in 3D object types or can be derived from them.)
  • Create icons for the four different shape types. You can copy images from the internet, or take screenshots of the objects you're creating. Show the icons in the four quadrants of the radial menu.
  • When the user hovers over one of the four items it should be highlighted before the user clicks on it.
  • When the user creates a new shape with the radial menu, a new block of this shape should show up in the user's hand and it should be colored white or grey. By default the objects should be about 10cm wide (or whatever size works best for your VR setup).

Here is a sketch of the radial menu:

Radial-menu.jpg

The icons for the four shape types should be 2D images, not 3D models.

Stationary Menu

Create a rectangular stationary menu and place it on the table in front of the user (or off to the side of the user's dominant hand). This menu should always be visible. Its overall size should be similar to a typical computer keyboard (~30-40cm).

This menu should have the following widgets:

  • Four buttons to change the selected object's color to red, green, blue or yellow. The buttons can be round or rectangular. To change the color, the user should put their controller on the respective color button and pull the trigger.
  • A dial to change the size of the selected block (all three dimensions equally). To interact with the dial, the user should click on it with the dominant hand's controller, hold the button down, and rotate the dial by only parsing the rotation of the controller around the forward axis of it. The dial in the menu should visibly rotate along with the controller's rotation, and the selected block's size should change as the user rotates the dial.
  • A slider to change the amount of gravitational force (affecting all blocks equally): when centered it should be what we are used to on Earth, but you should be able to reduce or increase this force to 1/10th or 10x (respectively) with the slider. To interact with the slider, the user has to move their hand to the slider knob, hold down the trigger, and move the knob while the trigger is held. The knob should only respond to the horizontal component of the controller's movement.

All widgets on this menu should be actual 3D objects.

Here is a sketch of what this menu could look like:

Desk-menu.jpg

Other Requirements

  • The user has to be able to grab any object by moving their controller to it and holding the trigger button, and moving it to a new location where they release the trigger. At that point the object should fall with gravity and tumble over other objects to the table surface as it would in reality.
  • Grabbing an object and hitting other objects with it should whack them similarly to what would happen in reality.
  • The most recently selected block should be highlighted with a method of your choice, for instance the same as in project 3. This highlighted block should be the one that is affected by the color and size changes in the stationary menu.
  • The only button you are allowed to use is the trigger on the dominant hand's controller. You are not allowed to use the joysticks on the controllers.

Notes:

  • You do not need to implement any travel method for the user. But all 3D components of the software should be set up so that they can be comfortably reached from a seated position.

Extra Credit (10 Points)

You can choose between the following options for a maximum of 10 points of extra credit.

  • Add sound effects to your application for any clicks in menus. Use different click sounds for the radial menu and the stationary menu. Also use sounds that you adjust the pitch of for the dial and the slider. (5 points)
  • Create a color selector for proper RGB color selection with sliders or dials. (5 points)
  • Object delete

(You may request other innovative features you implemented for extra credit!)

Submission Instructions

Once you are done implementing the project, record a video demonstrating all the functionality you have implemented by using the menu to create various building blocks, place them on the table or on other blocks, and change sizes and gravity.

The video should be no longer than 5 minutes, and can be substantially shorter. The video format should ideally be MP4, but any other format the graders can view will also work.

While recording the video, record your voice explaining what aspects of the project requirements are covered. Record the video off the screen while you are wearing the VR headset.

To create the video you don't need to use video editing software.

Components of your submission:

  • Video: Upload the video at the Assignment link on Canvas. Also add a text comment stating which functionality you have or have not implemented and what extra credit you have implemented. If you couldn't implement something in its entirety, please state which parts you did implement and expect to get points for.
    • Example 1: I've done the base project with no issues. No extra credit.
    • Example 2: Everything works except an issue with x: I couldn't get y to work properly.
    • Example 3: Sections 1, 2 and 4 are fully implemented.
    • Example 4: The base project is complete and I did z for extra credit.
  • Executable: Build your Unity project into an Android .apk, Windows .exe file or the Mac equivalent and upload it to Canvas as zip file.
  • Source code: Upload your Unity project to GitHub: either use the Unity repository initialized from GitHub Classroom or any GitHub repository that you might set up on your own. Make sure you use the .gitignore file for Unity that is included in the repo so that only project sources are uploaded (the .gitignore file goes in the root folder of your project). Then submit the GitHub link to Gradescope by using 'Submission Method: GitHub', along with your Repository link and the respective GitHub branch. (Note: GitHub Classroom is only for starter code distribution, not for grading. Since we don't have any starter code for HW1, you can set up your own repo with Unity .gitignore file we provided and submit to Gradescope too.)

In Summary, submit to Canvas with 1. Video and 2. Zipped Executable files (.exe, .dll, .apk, etc.), and submit to Gradescope with 3. Source Code.