Thursday, April 28, 2011

Posters and Presentation

So today was the CG@Penn poster session and senior project presentation day. They both went amazingly great. I would upload my presentation video, except it is a gig and it would take about 6 hours to upload to youtube. So this up coming week I am going to work on the final report for the project so I can move on and get ready for SCA submission. So short post for today, but it has been a long day.

Thursday, April 21, 2011

Oooooh Pretty....

Hey everyone,
So I've been up to two things this week. The first is the poster for the CS and CG@Penn Poster sessions. If you would like to see the poster, come by the SIG Lab from 2:30 to 3:00 on April 28th.
The second thing I did this week was get Maya rendering to work. Thanks to Igor, I was able to quickly teach myself a little mel and keyframe all the points I needed. I wrote out all the vertices in a diagonal fold and unfold and brought them into Maya. I then created a quick paper shader and put the paper over a ground plane. The video is below:


So Joe complained that there was not memory feed back or a crease mark left in the paper. So I am currently rendering out a new version with both those things. I also tried to get a dual color going, but I could not get it to work how I wanted. So unless people know how to assign two different colors to a polygon, I think it will remain one color for now. I tried rendering out my dog, but it is having problems. I will try to deal with them before my presentation.

So while getting maya rendering work I believe I figured out how to use rotational springs to procedurally add memory to the lattice. I create a rotation spring along the exact same axis of the crease that generated the change in memory. Since my rotation springs allow for more than 2 particles to affect, I push an entire face of particles onto this new memory rotation spring. I set the rest angle to something between 0 and Pi. Since the torque generated on each point is dependent on the distance to the rotation axis, larger torques are given to points closer to the axis. So a smooth curve out is created. You can reverse the direction or the degree of the curvature by changing the angle. It looks like this:



This image also has my crease texture along the diagonal that I'll be using for the animation later.

So this weekend I will be preparing my presentation and making sure that is all in order. After that I will take a look at memory and physical properties again for my final report. Almost there!

Thursday, April 14, 2011

Material Matters

Hey Everyone,
So this past week I've worked on two things: memory and material properties.

Memory has been a massive pain in the butt, which is surprising because I thought it would be easy to work with. In my previous post about memory my only somewhat successful memory attempt was done through relaxing the rest length of bend springs. I was relatively happy with that to capture a piece of paper that is incredibly curled up. But it was hard to get it to get slightly bent. So I spent a lot of time trying to get the rotational springs to be added procedurally but regardless of what I did it seemed like it would not work. So I decided to just hard program it and I realized that it required very slight adjustments of the rest angles of the rotational springs to get that slight curl. Take a look at the video below:

So in conclusion of the memory, you can get strong results for memory by playing with the rest lengths of bend springs and this can be done procedurally. However if you want to get slight curl due to moisture or it is light paper, you are better off putting rotational springs in there manually and tweaking them.

So when I say "material properties" I of course mean something that is more visual than something that is grounded in physics. I found this webpage : http://www.paperonweb.com/paperpro.htm and it has a great amount of physical properties of paper.
  • The major thing that you have to deal with here is the weight of the paper. So I spent some time playing around with the mass of my particles. What this did visually was it mainly affected how great the forces were acting upon the particles. Mostly this just slowed down or sped up the folding process. However because it changed the speed of the fold, it did make the paper slump or stiffen a little more than usual. So changing the mass definitely had an effect.
  • The second property that I deal with is curl. I talk about the curl in my memory portion above. This website lists three different types of curl with regards to paper. When I add rotational springs this is sort of like structural curl, where a difference in the fibers causes the paper to pop up. When I change the bend spring's rest length that is sort of like moisture curl, where fibers in the paper either collapse or expand due to exterior forces or moisture.
  • The third major property I deal with is the dimensional stability. Dimensional stability is basically how the fiber in the paper keeps the paper together and affects how it folds. This is akin to my spring constants. I spent a lot of time playing with settings of spring constants to get different affects. Reducing the constants of the shear and bend springs will make the paper much more cloth. Reducing just the shear springs will make the paper more like tissue paper. Reducing just the bend springs will make the act like it is more moist. Reducing the constants of the structural springs is just bad because then the paper no longer holds its form.
  • The last property I got from that website was formation. Formation is the alignment and distribution of the fibers in paper. I wrote code that offsets the points in the lattice by a random but clamped epsilon. However this did not seem to change much in my simulation. I think it would be more important if I worked in a very large lattice.
I've attached videos of some the presets I've created for my simulation and showing what I described above.







Next week I am going to just concentrate on rendering. I have a problem where the paper can be folded at odd angles, causing breaking. I need to look at Joe's Maya export code before I can come up with a firm idea of how to solve this problem. After I do the rendering I am going create my poster and get ready for my final presentation. Yay!

Friday, April 8, 2011

A Dog's Life

An update? Not on a Thursday night? Is this bizarro world? No. In the last post I did not get to put up any movies. So this morning I laid out everything I needed to fold the traditional dog model and wrote up the XML file. I made her a slightly larger lattice than I have been working with. She is 25x25 opposed to the 13x13 I've been working with. So here she is, my first complete model in my simulation:




I know the top edges on the head are a little weird, but that is because the folds are occurring at weird angles. So I am going to have to deal with that when I get to the Maya export and rendering. I think I can fix it when I get to Maya, otherwise I may just live with it.

Thursday, April 7, 2011

Beta-Max

Hey Everyone,
So this week I tried doing two new implementations of my rotational springs. The first one I did earlier this week was an implementation recommended by Steven Gray. Rather than just applying forces to the corner of the lattice these rotational springs apply forces to multiple points. I originally tried applying forces to the points that neighboring the rotation axis. However because the lattice is not incredibly stiff, it only moved those neighbor points across the axis and did not move the entire paper. So I changed the implementation so that all the points above the a rotation spring are affected. So basically an entire rigid body is folded here. This proved to have better results since the forces added on each point are proportional to the distance from the rotation axis. However I feel that it becomes much harder to control where points are moving with this method.

This lead me to the another new implementation. In this implementation I once again allow for multiple points for the torque to act upon. However it is only used when acting upon an edge rather than a corner. This way I can use only one rotation spring in a horizontal/vertical fold rather than two as I was doing in the past. I also setup an XML input method that makes sure that each torque point has a structural spring to help support it. I also make sure that the structural springs turn off when that rotation spring is not active because they can interfere with other rotation folds. Because I changed the XML format for this new rotation spring I spent an hour going through and updating my previous XML files, making sure each one still worked. Some of them did not, which helped me find bugs.

This was all leading up to trying to fold the traditional dog model. This paper: http://www.csc.calpoly.edu/~zwood/research/pubs/origamiCATA06.pdf shows intermediate steps folding the traditional dog. I was able to put together most of the folds for the dog, but it is not quite finished yet. I still want to make tweaks to it and try it on a slightly larger lattice. However I am now 95% sure that I can fold that model with my simulator, which is great. The traditional dog does have a squash fold in it, which does make it technically not pureland. So maybe in the future I can get other stuff working.

So this past week was also beta review. I think it went well. The major thing it did was change how I am going to approach the last few weeks. The first thing is no more GPU implementation. I am going to concentrate on getting memory and material properties worked out so I can put them in the report and on my poster. After I finish those I will use Joe's code for taking the jello cubes into maya and do a bunch of nice renders and animations for my final video. If I have time after that, which I won't, I'll try to get a simple UI built so I can draw out folds rather than writing the XML. So my schedule as it stands is:

April 8th- 14th
  • Memory
  • Material Properties
April 15-21st
  • Rendering
  • Poster
April 22nd-April 26nd
  • Presentation
  • Simple UI (Probably not)
April 29th and Beyond
  • Final Report
  • Commenting Code
I know this post did not have any videos in it, mainly because today was kind of an annoying day. Next post will have videos, including the folding of the traditional dog. So look forward to it.