Skip to content

This is a plugin for automatically creating a custom wine glass mesh inside 3dsMax.

License

Notifications You must be signed in to change notification settings

the-other-mariana/wine-glass-plugin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Wine Glass Plugin for 3dsMax

This is a repo that contains the script in MAXScript Language that creates a plugin to automatically and procedurally generate any type of wine glass cup mesh object. You can export the object as .obj, etc.

Usage

This was made in 3dsMax 2020.

  1. Download this file and store it in your computer.
  2. Open 3dsMax.
  3. Click on Scripting tab.
  4. Choose MAXScript Editor.
  5. On the editor, go to File > Open File > /Downloads/wine-glass-v3.ms, to open the downloaded script from step 1.
  6. Type Ctrl + E to run the script.
  7. Find the plugin in Wine Glass Plugin category of meshes in 3dsMax Mesh Category dropdown menu.

Progress & Logic

1st Round

First defined 5 essential sections, just as the teapot. Then created a cylinder where each section has N number of segments. This is so that if the user inputs segments = 1 it can still look like the minimum form of a wine glass.

Then just defined each section's radius and interpolated the current radius with the next.

alt text

2nd Round

What I did was simply clean a bit the parameters of heights: I added a spinner for the wine glass body scale and determined all the other section's height with respect to it. Next thing to do is round section 4 (below the body).

alt text

3rd Round

This time I made section 4 (between handle and body) have an option to be curved or simply straight, using spheric coordinates. Separated Segments parameter to just apply to sections 2,3 and 5 (bigger sections) and sections 1(foot) and 4(belly) (smaller sections) to have their separate amount of custom sections.

alt text

4th Round

I made section 4's curve to be calculated automatically (inverse tangent!) and the curve can have a better look even if there are a lot of sections. I also closed the model in top and bottom. Added closure factor slider for the cup's mouth, but erased the angle parameter in the belly curve which didnt really improved the model and now is calculated.

alt text

5th Round

This time I found that smoothing groups in 3dsMax are set according to powers of two: if you want a face in smoothing group 4 (N), you need to write 2^(N-1), that is, an 8. So I set every section to its own sg, except when Belly is on (1), because then section 5 must have the same sg as section 4 (belly) so that it looks nicely blended.

alt text

A picture of probably all final parameters is shown bellow.

alt text

Final version

Current script is this file. An example would be the following.

alt text

And the smoothing corrected as mentioned.

alt text