Realtime mesh deformation of soft objects [closed] - c#

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 3 years ago.
Improve this question
My problem is simulation of soft object deformation on user interaction, like when you touch ball with sand inside it deformes its edges in spots you press on ball. How can I achieve it in Unity3D?

Soft body dynamics is a very complex topic, which is why most physics engines constrain themselves to rigid body dynamics. I am pretty sure that no one on StackOverflow is going to code this for you. There are some commercial solutions for Unity though, Obi Softbody and Truss Physics to list a couple.
Here is a cheaper but probably less feature complete option:
https://assetstore.unity.com/packages/tools/physics/b-soft-body-deformation-53378
There are many different ways for simulating soft body physics, one common way is to map the vertices to a lattice of points (with some weight), and then simulate spring contraints between the lattice points. These types of lattices are probably best simulated with verlet integration.
Here is a research paper on lattice shape matching.
Here is another paper on pressure models.

Related

How to make GameObjects Solid [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 2 years ago.
Improve this question
So i want to make my first game, and it is with driving. I import a car and a race mape (Lake Race Tack) from Unity Assets Store,and when i drive my car enter se mountains,rocks 'n trees. How can i make the map solid?
If you want to have solid shading, you should use the edge split modifier on the mesh. You can have it split edges that are marked sharp, by angle, or both. Make sure you check "Generate Colliders" on your mesh's import options.
I found a simple solution to this answer. Select the object you want to make solid and click "Add Component" then go to physics>mesh collider> check convex and add a material and mesh . This should do the trick.
To Make Objects Solid you need to add COLLIDERS to the objects so that the objects don't pass through each other.

In 3D Racing Games, how is place determined? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I was following this tutorial:
https://www.codeproject.com/tips/357063/a-very-simple-car-race-game-in-csharp-and-opengl
Determining place in this game is trivial, as the cars only move in one dimension on a straight line. How would it be done in more generic maps with the cars moving in more than one dimension?
EDIT:
By place, I mean 1st, 2nd, 3rd place, ad nauseum.
How do you determine which car is closer to finishing than the others?
In 3D Racing Games, how is place determined?
By that I assume you mean position.
If so by a simple scalar quanity.
Cars on a 3D race track in a computer or reality, are still constrained to being on a "road". Assuming no intersections, you can ignore the third dimension. Because a track is a loop, you can also unwind it and any point on the path can be a scalar value between 0 and 1 with:
0 being the start of the track
0.5 half-way along; and
1 reaching the start again

How to make a Unity3D game just using C# [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
And is that possible for Unity3D to do the same thing like Opengl to draw the vertices on the screen?
What I want to do is to migrate a XNA project to Unity environment in order to make it cross different platforms.
Maybe using Meshes will do the work for you :)
You can render meshes consisted of vertices & normals & uvs & indices.
Click here for the documentation
If you must have custom rendering there are GL and Graphics classes you can use. Render to texture is possible too. In Unity, code is usually written in class that inherits MonoBehaviour and it has Start, Update (once per frame), FixedUpdate (physics) and other callbacks for you to use.

Game Programming Newbie -- In Game Objects as Required [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
I've done some volunteer game programming in LPC for a MUD in my past and everything there was easy. If I wanted a new item I would just use a function to load (for example an NPC) as many times over as I wanted. Now I want to program my own little game I cannot for the life of me identify what I even need to do. If I get nothing more than the name of what I want to do in order to carry out my own further research, that would be enough. Having rambled on about all of that, on to my question:
I want to make on the fly instances of in-game objects (for example people), some handled by the computer, other handled by the player. A lot of the help on game programming I've found has been about making sprites move and handling collision detection. This is all great, but I want to code a strategy game and so am more interested in creating some sandbox flexibility within my game and coding the AI to provide the interest, rather than swish graphics and awesome sounds, etc. I want to setup the game with a variable number of randomly generated people for the player to interact with. So far I've created a class to handle the people, but I'm now stuck as each instance of the class needs a unique name and I programming in that would mean there was no randomness in the number.
What would I need to look up to achieve what I'm after? What would it be called? Have I even explained myself with any degree of eloquence?
Thank you in advance for any potential help that might come my way.
Matt.
What you're looking for is something like RPG name generators (google it).
Basically those sites you'll find generate their names out of a random combination and concatenation of prefixes, syllables and suffixes. I don't know where there is research on this topic, but you could start with something like that.
Edit: you could use Markov chains, they are used for text generation.

Shape recognition in image [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I need help with one application, I am a beginner in programming.
So I need to create a simple application that recognizes shapes in the image (rectangle, triangle, line ...) rendering them. (for an experienced programmer to be easy :D )
Here are similar projects, but I was the only one to not know much about: http://leakingmemory.wordpress.com/2012/03/17/shape-recognition-using-c-and-aforge/ and http://www.emgu.com/wiki/index.php/Shape_(Triangle,_Rectangle,_Circle,_Line)_Detection_in_CSharp
Thank you very much
EDIT:
Can you tell me how to portray all the polygons? Not only a triangle, circle ... but all shapes?
If you really want to attempt this, I'd suggest looking into Edge Detection to start. Both of those articles you linked to start by processing the image and finding the edges. The first article uses a Sobel filter, whereas the second uses Canny edge detection. Once you have a better understanding of this concept, you can make use of a library like AForge to handle doing it for you.
The next step would be to write the logic that will be used to detect the vertices of joined edges that were found from the previous step. With that in place you can detect triangles (3 vertices), squares (4 vertices), or any other arbitrary polygon.
Detecting a circle seems like it would be a bit more difficult (the second article looks to "detect" a circle by removing anything that's not a circle). If you've made it to this point though, I'm sure you could do a bit of googling and find some techniques that other people use to detect circles, and you can use the code you now have as a starting point to implement it.
Good luck!

Categories