Questions tagged [mesh]

A collection of vertices, edges and faces that defines the shape of objects

Filter by
Sorted by
Tagged with
0
votes
1answer
40 views

Rotate mesh to normal

I have some instanced geometry (basic tube meshes) laid out in a grid, and I have a noise texture (normal map) that I want to use to rotate my instances with. So head pixel in my texture is a normal ...
0
votes
1answer
52 views

Physics.CheckSPhere is not working

I try to use Physics.CheckSphere to check if a coordonate is empty. I use three for loop to cycle threw a 2 x Y x 2 chunk. The problem is that it return true if the corner is touching the coordonate ...
0
votes
1answer
20 views

custom mesh object orientation is not correct using

I am making a custom mesh with the help of Traingulator script. At runtime, user can click and and generate a point then mesh creation start. Here is the way i am getting user input. ...
0
votes
0answers
35 views

Game Object's Vector3 changing through script without reason

I am trying to do a combine block script. However, I encountered 2 problems: the blocks / the combined mesh isn't showing up anymore when it was, all the blocks where at the same location Even ...
2
votes
1answer
44 views

How do I correctly show both sides of a plane in Unity?

I am trying to show both sides of a mesh. I understand this question has been asked a lot, but all of the answers I've found seem like they're written for Unity 5 and I can't find a "Cull" setting on ...
1
vote
1answer
35 views

Smooth shading along edges with duplicate vertices

On this generated mesh, I have sharp edges, because each square has duplicate vertices separate from its neighbours. I can't remove the duplicate vertices because I'm using them to provide unique UV ...
2
votes
1answer
32 views

On changing a voxel, don't recombine everything again, only modify the changed parts?

I'm working on a voxel based game, where destructible structures are made out of cubes. (Some of them has 3000 voxels) I solved the framerate issues by combining them, but after making it able to ...
0
votes
0answers
17 views

Unity - How to add bones to procedural mesh

Basically this is the set up: An N amount of prefabs are bundled together into a new GameObject. This is then merged into a single main mesh composited of M amount of material submeshes. The shape is ...
0
votes
0answers
23 views

Measure the length of the mesh

I have a boat race game. I have a curved mesh, that is the track. How can I measure the map(mesh) length, so I can place checkpoints on every 1/5 of the length?
0
votes
0answers
28 views

Unity: How to fix shadows with several meshes in different objects?

I'm creating many GameObjects and each one has a single mesh, created in a script. The problem is that I would like to draw them so that they behave like a single mesh. Is it possible? Or I must ...
1
vote
1answer
45 views

Calculating approximations of contact between two meshes

I'm looking for ways to calculate the degree of contact between two objects in a scene. I was thinking that calculating the hausdorff distance would be a useful approximation if it is then normalized ...
0
votes
0answers
25 views

DragonBones mesh gets light by the wrong side

So, I use DragonBones to get skeletal-animation in my Unity 2d game. The problem is that object is affected by light only from the back, while other objects(sprites, while the first one is mesh) from ...
0
votes
0answers
21 views

Can't refer mesh size after using .BakeMesh() in Unity

I can't figure out how to refer to the size of a particular mesh. The mesh is created through .BakeMesh(), then a box collider is added. Unfortunately the box ...
0
votes
1answer
223 views

Show Sprites on Overlap (Shader Graph) [2D]

I have a character sprite mesh and mesh renderer (The black wavy box). I am hoping to be able to overlay the black box onto the character covering the sprites but I am not sure how to do that. I ...
0
votes
1answer
209 views

How to change the mesh of the character in UE4?

I made a Bellsprout mesh in Blender, exported it as an FBX file, and imported it into UE4. I can insert it in the stage without problem, but I would like to use this Bellsprout mesh to replace the ...
0
votes
0answers
40 views

Hi,Dynamically modifying meshes in Unity3D

I'm working in Unity3D and I want to remove sections from a mesh at runtime similar to the idea of bombs removing sections of walls. In 3D modelling software this is a pretty standard Boolean ...
0
votes
1answer
52 views

LineRenderer on Mesh surface

Goal: Render distance lines between two points on the surface of a mesh-based primitive (i.e. sphere, cube, etc). Current Solution: Iteratively traverse distance line between two end points and "...
0
votes
0answers
15 views

TextMesh animation not working when attached to a new TextMesh object

I created an animation on one TextMesh object. Then I duplicated the TextMesh object (Ctrl-D) and disabled the first one. The same animation is - of course -attached to the new TextMesh. However, it ...
1
vote
1answer
94 views

How can one replicate the 'Quake Disruptor' of Wipeout XL/2097?

Following my previous question, I am wondering how one can achieve the same effect under Unity? The effect in action https://youtu.be/kzmmLeCwL0g?t=790 Description of the effect When you fire the ...
2
votes
1answer
113 views

Mesh rendering performance optimisation

I'm working on a libgdx implementation of mesh terrain and running into some performance issues. The terrain is represented by a number of mesh tiles, each mesh is made of vertices laid onto a 2D ...
0
votes
0answers
37 views

Why my mesh is flat and change position?

Befor Start: (It's basic cube) After Start: (It's must be Eye) Code: IngredientAsset: ...
1
vote
1answer
83 views

Unity SphereCast HitInfo Give me an interpolation of the normal surface?

I'm doing a SphereCast for a GroundCheck of a player. I have my Raycast hitInfo, and here in the picture at the left, I Debug.drawRay in black the direction of the hitInfo.normal every frame It seems ...
0
votes
1answer
40 views

split/divide/extract/separate mesh indices&vertex in n

I'm totally lost. I'm trying to split/divide/extract/separate a mesh into sub-meshes via bbox test. But I just realized that I need to properly split indices and vertex and I have no idea how o.o... ...
0
votes
1answer
46 views

Sometimes can't use the rendered mesh as a collider in Unity?

Most of the times I can use the Mesh Filter's mesh as collider in Mesh Collider But sometimes there is just nothing. No ...
0
votes
0answers
15 views

Unity inflates poly/vertex count but I don't have any lights?

Ok I have an issue with several meshes that have a lower poly count in blender, then when I export as fbx and bring into unity, the poly/vertex count skyrockets. I read here https://forum.unity.com/...
0
votes
0answers
27 views

Generating skeleton bind pose from vertex weights

Assuming that you know how many bones should be in the skeleton, and you have the bone hierarchy, is it possible to calculate the bind pose of the bones just based on the vertex weights? To elaborate ...
1
vote
0answers
50 views

Convert bones by bone matrix

I have a 3d-models from old game. They have the following structure: ...
1
vote
1answer
283 views

How can we achieve Earthquake Simulation in Unity - Simulation of P and S Waves

I Cannot use Water waves as P and S Waves are different than water waves. I tried to use it but not satisfied with the result. I am trying to simulate how Earthquake takes place in real time which ...
0
votes
0answers
265 views

Algorithmically fracture a mesh in Unity3D?

I want to create a plugin which shatters/fractures meshes, so I can make every object destructible if I want to. Like in Unreal's built-in feature. My quick approach to this problem is randomly ...
0
votes
1answer
304 views

Unreal 4 - How to access and iterate through the polygons of a mesh?

I'm newbie with Unreal Engine 4. I need to create a function which calculates the volume of a mesh, based on the following example: https://n-e-r-v-o-u-s.com/blog/?p=4415 To achieve that I created ...
0
votes
1answer
42 views

How do I determine distance of a point within a ProBuilder mesh?

As in the title, I have an effect prepped for my game which applies certain derived parameters to a post-processing effect after the player enters a boundary I created with ProBuilder. Finding how far ...
1
vote
1answer
152 views

Unity: How do I only show parts of objects that overlap [2D]

I'm working on a 2D Unity project where the player can only see objects in their field of view. I have successfully created a mesh that overlaps anything that would be in the player's field of view, ...
1
vote
1answer
158 views

Unity block chunk generation pattern

I am trying to do something like Minecraft game in Unity. Currently I am trying to generate a chunk of blocks, given dimensions. I can successfully create a chunk of N x 0 x 0 sized chunk, but due to ...
0
votes
1answer
246 views

Unity3D - Mesh appears black in parts that it shouldn't

I have a procedurally-generated mesh that I am generating to use as a terrain. It looks something like this (from above, and it changes slightly every time): It also looks fine when I view from the z-...
0
votes
0answers
85 views

TTF glyph to OBJ

I'm looking for a method to convert a TTF glyph into a triangle mesh. I've tried making my own font constructing my own indices and vertices but it didn't go well: ...
2
votes
2answers
616 views

How can I generate the smallest enclosing sphere from a mesh?

I have a polygon which is defined by a set of vertices and I need the smallest sphere encompassing the mesh. The spheres are defined by a position vector (x,y,z) and a radius. Is there an algorithm ...
0
votes
2answers
375 views

How can I convert my list of vertices and indices to a list of triangles?

I have a full 3D collision mesh that is represented by a list of vertices and another list of indices. I need to convert the list of vertices and the list of indices into a set of triangles. First I ...
0
votes
1answer
33 views

.md5mesh - multiple meshes with smooth normals

I have a .md5mesh which contains multiple meshes and I want to calculate smooth normals. The normals are correct but they don't work with multiple meshes. My first idea was to merge all meshes, then ...
0
votes
1answer
264 views

Removing duplicate vertices on a mesh

I have a set of vertices and another set of indices. Sometimes I find that I have duplicate vertices in my mesh. I tried at first to check if two identical vertices were in the array of vertices but ...
2
votes
2answers
148 views

Why does Unity's MeshCollider only use SharedMesh?

For components like MeshRenderer, Unity uses two references to mesh through script--mesh, and sharedMesh. My understanding as of yet that setting a "sharedMesh" will affect every GameObject that uses ...
0
votes
0answers
25 views

Finding the “top” of a mesh representing the terrain

I'm generating a low-poly mesh for terrain, and for a given world coordinate I'd like to know where the "ground" is. My game uses fairly standard infinite terrain - I generate noise values for world ...
0
votes
1answer
32 views

Combining meshes up to certain sizes

I have the following spritesheet for types of terrain, with a transparent background. To draw it on my map, I thought of doing one mesh per type, and then combine them. This is the code. This gave ...
0
votes
1answer
95 views

How to get a reflex edge on a non-convex mesh

I am trying to implement a convex decomposition and I need to find the convex vertex on a mesh. Is there a algorithm that I can use to find the convex vertex on a mesh.
-1
votes
1answer
202 views

How do I get extents in my mesh

I am creating a AABB for collision detection. I need to calculate the extents for my model and also update them when my model moves. I calculate my min and max when I create my mesh and I use my ...
1
vote
1answer
57 views

Creating a large ground texture for mobile

Does anyone has any insight on creating / texturing a large mesh that will be used for a mobile game's level map? Specifically, I was wondering how games like Vainglory achieve this. I am familiar ...
-1
votes
3answers
335 views

How do I get min/max on a mesh

I am trying to create an AABB but I need to know how to store min/max from a mesh. Here is my code(I got it from thin matrix) : ...
0
votes
1answer
35 views

Divert gameobject around mesh surface

I am trying to find a way to divert a vector3 position around the surface of a mesh which doesn't have a collider. I have a function (found online) that calculates the closest position on the surface ...
0
votes
1answer
209 views

Determining if a point is perpendicular to a line

I am trying to walk a line that is intersecting a mesh, and given the point on the line I need to see what vertices may be perpendicular to it. My initial idea was to attempt a dot product between the ...
3
votes
0answers
166 views

Understanding unknown mesh data structure

I have a large number of old mesh files in a custom, undocumented binary format. I have managed to parse almost everything but am left with one group of structures, described below, that I don't ...
0
votes
1answer
215 views

Problem with Unity NavMesh tools

I'm getting this error: Runtime NavMesh Builder source mesh combined mesh is skipped because it does not allow read access I checked all the models and it has the read permission. I also noticed,...