UI for Python Application - Base Function - Python Mathematics Library - Computer Science Assignment Help

Download Solution Order New Solution
Assignment Task:

1. Create a test scenario in Maya  

a. Encapsulate one object within another (e.g. a cube within a larger sphere)  

b. Understand that your assignment will be evaluated with other objects (not  spheres and cubes) but one object will always encapsulate the other  c. Assume that the object pivots will remain at the center 
 
2. Create a UI for your Python application 

a. You’ll need at least one button and a text field to work with 
 
3. Define a base function findIntersect(), which is called from a button in the UI 
 
4. In the findIntersect() function, perform the following tasks:   

a. Verify that only two objects have been selected 

 i. Assume whichever object is selected first is the reference object  

ii. Hint: The command “ls(selection=True)” will return the objects as they  were selected so the last one selected is the last one in the list  b. Using the outer object as the reference, create lines using the outer object’s pivot  and each of the outer object’s vertices  

c. Determine the intersection point of each line with the inner object  

d. Place a new cube at centre of the intersection point  

i. The cube should be sized at 0.1 for all dimensions  

e. In the UI, for each intersection point, provide the following information:  

i. The point’s position 

 ii. The position of the points of the intersecting line 

 iii. The area of the intersected triangle  

iv. The distance of the intersecting point to the outer object’s vertex  

v. The normal vector of the intersected triangle 

vi. The angle the intersecting line makes with the grid  Requirements  

  •  All script must be written using Python, using the Maya API  
  •  All functions you use (Cross-Product, Dot Product, Normal Vector, etc.) should be  defined as clear, generic functions  
  •  Code from the tutorials is expected—don’t bother to try to rewrite it in your own way  
  •  While the standard Python mathematics library (math) is accepted, no other libraries  may be used (such as NumPy)  
  •  The inner and outer objects should be obtained using the selection method, rather than  by name 
  •  The plane equation must be determined by using the normal vector and scalar value, not  the equation used in Tutorial 2 .

 

This Computer Science Assignment has been solved by our Computer Science Experts at My Uni Paper. Our Assignment Writing Experts are efficient to provide a fresh solution to this question. We are serving more than 10000+ Students in Australia, UK & US by helping them to score HD in their academics. Our Experts are well trained to follow all marking rubrics & referencing style.

Be it a used or new solution, the quality of the work submitted by our assignment experts remains unhampered. You may continue to expect the same or even better quality with the used and new assignment solution files respectively. There’s one thing to be noticed that you could choose one between the two and acquire an HD either way. You could choose a new assignment solution file to get yourself an exclusive, plagiarism (with free Turnitin file), expert quality assignment or order an old solution file that was considered worthy of the highest distinction.

Get It Done! Today

Country
Applicable Time Zone is AEST [Sydney, NSW] (GMT+11)
+

Every Assignment. Every Solution. Instantly. Deadline Ahead? Grab Your Sample Now.