Skip to main content
Explaining problem in more detail.
Source Link
DMGregory
  • 136.3k
  • 22
  • 247
  • 373

Find all points projecting onto a given pointtriangle for UV mapping in RuneScape model format

I have 2 triangles ABCam using an old Runescape model format, also used by Thief and PMN

I want to generalize the triangle PMN from points to linesQuake. In this format, where any choice along that line will produce the sameinstead of specifying UV mappingcoordinates for the triangleeach vertex ABC

Basically i want to find all triangles that project to, we specify a given setsecond trio of vertices PMN. Those vertices are then used to project UV texture coordinates onto ABC.

And as the projection throws away one dimension that should be infinitely many, but they should have some orderingSome previous Q&A explains this projection algorithm and how to reverse it.

So i should be able to start with one and then walk alongI have a linemesh with UVs that I want to save in this format. To do that, I want to find alla trio of vertices PMN for each triangle ABC that reproduce the correct UVs.

i am not sure on how iThese PMN vertices are chosen from the collection of vertices already in my mesh.

I could do thatsearch every possible ordered triangle in my mesh, any advicebut that scales as \$O(n^3)\$ and would be appreciatedimpractical for meshes with high vertex counts.

FormulaHow can I more efficiently find a PMN triangle that createsproduces my desired UV mapping fromcoordinates on each triangle PMN & reverse: reversing plane projection texture mapping algorithmABC?

Find all points projecting onto a given point

I have 2 triangles ABC and PMN

I want to generalize the triangle PMN from points to lines, where any choice along that line will produce the same UV mapping for the triangle ABC

Basically i want to find all triangles that project to a given set of UV coordinates

And as the projection throws away one dimension that should be infinitely many, but they should have some ordering

So i should be able to start with one and then walk along a line to find all

i am not sure on how i could do that, any advice would be appreciated.

Formula that creates UV mapping from triangle PMN & reverse: reversing plane projection texture mapping algorithm

Find projecting triangle for UV mapping in RuneScape model format

I am using an old Runescape model format, also used by Thief and Quake. In this format, instead of specifying UV coordinates for each vertex ABC, we specify a second trio of vertices PMN. Those vertices are then used to project UV texture coordinates onto ABC.

Some previous Q&A explains this projection algorithm and how to reverse it.

I have a mesh with UVs that I want to save in this format. To do that, I want to find a trio of vertices PMN for each triangle ABC that reproduce the correct UVs.

These PMN vertices are chosen from the collection of vertices already in my mesh.

I could search every possible ordered triangle in my mesh, but that scales as \$O(n^3)\$ and would be impractical for meshes with high vertex counts.

How can I more efficiently find a PMN triangle that produces my desired UV coordinates on each triangle ABC?

included formula
Source Link
Suic
  • 119
  • 6

I have 2 triangles ABC and PMN

I want to generalize the triangle PMN from points to lines, where any choice along that line will produce the same UV mapping for the triangle ABC

Basically i want to find all triangles that project to a given set of UV coordinates

And as the projection throws away one dimension that should be infinitely many, but they should have some ordering

So i should be able to start with one and then walk along a line to find all

i am not sure on how i could do that, any advice would be appreciated.

Formula that creates UV mapping from triangle PMN & reverse: reversing plane projection texture mapping algorithm

I have 2 triangles ABC and PMN

I want to generalize the triangle PMN from points to lines, where any choice along that line will produce the same UV mapping for the triangle ABC

Basically i want to find all triangles that project to a given set of UV coordinates

And as the projection throws away one dimension that should be infinitely many, but they should have some ordering

So i should be able to start with one and then walk along a line to find all

i am not sure on how i could do that, any advice would be appreciated.

I have 2 triangles ABC and PMN

I want to generalize the triangle PMN from points to lines, where any choice along that line will produce the same UV mapping for the triangle ABC

Basically i want to find all triangles that project to a given set of UV coordinates

And as the projection throws away one dimension that should be infinitely many, but they should have some ordering

So i should be able to start with one and then walk along a line to find all

i am not sure on how i could do that, any advice would be appreciated.

Formula that creates UV mapping from triangle PMN & reverse: reversing plane projection texture mapping algorithm

added 286 characters in body
Source Link
Suic
  • 119
  • 6

I have 2 triangles ABC and PMN

I want to generalize the triangle PMN from points to lines, where any choice along that line will produce the same UV mapping for the triangle ABC

Basically i want to find all triangles that project to a given set of UV coordinates

And as the projection throws away one dimension that should be infinitely many, but they should have some ordering

So i should be able to start with one and then walk along a line to find all

i am not sure on how i could do that, any advice would be appreciated.

I have 2 triangles ABC and PMN

I want to generalize the triangle PMN from points to lines, where any choice along that line will produce the same UV mapping for the triangle ABC

i am not sure on how i could do that, any advice would be appreciated.

I have 2 triangles ABC and PMN

I want to generalize the triangle PMN from points to lines, where any choice along that line will produce the same UV mapping for the triangle ABC

Basically i want to find all triangles that project to a given set of UV coordinates

And as the projection throws away one dimension that should be infinitely many, but they should have some ordering

So i should be able to start with one and then walk along a line to find all

i am not sure on how i could do that, any advice would be appreciated.

Source Link
Suic
  • 119
  • 6
Loading