Malo
-
Posts
314 -
Joined
-
Last visited
-
Days Won
7
Content Type
Profiles
Forums
Events
Posts posted by Malo
-
-
In my opinion, the export of information to the AM to a classic polygonal program is possible.
There are just two problems to solve.
The first problem is the triangle:
AM uses to the triangle, the patches 4 sides, and overwrites one of its sides, which creates a bad topology:
Is it possible to do otherwise ?, yes! The solution and the code is in Jpatch, the code is visible (in Java) (http://www.jpatch.com/)
The second problem are the hooks (3 types). the topology of AM or Jpatch gives no perfect solution. they create triangles. (with bugs in AM?)
One solution would be to get to create a topology like this:
Once solved this, I do not see what could block the export.
For import is more complicated ... There are different manner to do it for the purposes and different results.
Props, it could improve its ability for example by giving a subdivision level option and importing Mdd for animation.
patches, nemyax's plugin works well, it requires creating a retopology the model to fit the topology of the patches before the import.
Use AM to animate polygonal model, rasikrodri's plugin is promising for that.
The import/export of information of UV, bones, weigts, cameras, lights, scenes should not be a problem.
What is missing for AM is time, mathematicians and programmers. -
Rasikrodri Congratulations!
Wait to see more.
I see an interesting manner in this manner to import polygonal models: to use AM as an animation tool for polygonal models. Import / animate / export with Obj+MDD to be rendered in external renderer. -
Same with the other patch : you began with "3" you arrive to "4", but a new spline arrive, so you write "5", after no new spline so you wrte "8" and "7"
-
When a spline arrive where an another spline arrive, you must take the Cp of the new spline.
You began with "1", you arrive to "2", but there is a new spline, so you take the CP of the new spline "5" you go to "6", but a new spline arrive, so you take 3, and after no new spline so "2" stay.
-
There are different combination of CP to write a patch, for example 1 5 3 2, 5 3 2 1, 3 2 1 5... etc. but for each combinaison of CP the bitfield will be different. (It seem it better to began with the smaller CP)
I come back for the example 1 5 3 2, and explain it :
when I write the first patch in the orientation 1 5 3 2, the orientation is left, right,left, left. So the bitfield for that is 16
the second patch is 3 5 8 7, right, left, left, left. So the second bitfield is 8.
For the fun, it is possible to write a patche with only Cps from one spline with the bitfield 0 or 120 ( but when you will refresh, it will be clear) -
Could you tell me what is the bitfield I write where you don't understand, I will try to explain better
-
Yes the bitfield is tells how the patch should generated the geometry inside of it
The choice of 16 and 8 depends on the orientation of splines that form the patches.
nemyax might be better explain in good English, because he understood the bitfield -
There may be a solution :
You must use one single spline by polygons and peak them.
for example :
262144 0 1 -14.9114 7.65905 0 . .
262144 0 2 -15.9959 0.135558 0 . .
262144 0 3 -7.38793 -0.0677792 0 . .
262148 0 4 -7.25237 8.26906 0 . .
for
v -14.9114 7.65905 0
v -15.9959 0.135558 0
v -7.38793 -0.0677792 0
v -7.25237 8.26906 0
f 1 2 3 4
The patche will be a hole if there is only one polygone, but once you stick to another closed spline , it will be possible to write patches. for example :
for
v -14.9114 7.65905 0
v -15.9959 0.135558 0
v -7.38793 -0.0677792 0
v -7.25237 8.26906 0
v 1.83004 10.9802 0
v 8 2.57561 2.64339 0
f 1 2 3 4
f 5 4 3 6
you can write this :
262144 0 1 -14.9114 7.65905 0 . .
262144 0 2 -15.9959 0.135558 0 . .
262144 0 3 -7.38793 -0.0677792 0 . .
262148 0 4 -7.25237 8.26906 0 . .
262144 1 5 4 . .
262144 1 6 3 . .
262144 0 7 1.83004 10.9802 0 . .
262148 0 8 2.57561 2.64339 0 . .
16 1 5 3 2 0 0 0 0 0
8 3 5 8 7 0 0 0 0 0
Hope that will help you. -
hello rasikrodri,
I hesitate before answering because I don't speak english , so I 'm not sure I understand what is being asked . (sorry if this is the case.)
You converted to splines EVERY edges, so every spline is a line with two Cps . (As Hamapatch was to import the objects from Metasequoia ) . It can be a solution for not having ghost patches (holes) ... but you lose the subdivision.
To return to writing the patches, it does not seem that changed a few things, because a spline that have two or more CPs , it has an orientation that must be considered when writing the bitfield of patches.
-
Thanks!
-
Great! You got it ! Congratulations !
Thank you!
Note: By importing in a window model(right click, import/Model.mdl), it is imported perfectly (without refreshing)! -
What i mean is that :
The Patches is write as this :
bitfield CP1 CP2 CP3 CP4 ..
The CP1 must be the smaller CP (of all CPs, CPs attached too) if this is the CP that carry the coordinates, then it will be the CP attached to it.
To write UVdata:
0 CP1 CP2 CP3 CP4 ...
CPs are the same as for the patches (if a CP not carry the coordinates, so write the CP attached with the coordinates.)
-
Nice model.
There is some patches that are bad,
for example :
Splines :
1 1 787 720 . .
1 1 795 788 . .
1 1 963 960 . .
1 1 959 553 . .
Patches :
96 787 963 959 788 1650 2558 1443 2918 0
UV :
0 720 788 738 890 0.749089 0.562176 0.000000 0.741461 0.563332 0.000000 0.733834 0.564488 0.000000 0.726183 0.565647 0.000000 0.720098 0.537709 0.000000 0.714013 0.509770 0.000000 0.707909 0.481748 0.000000 0.718851 0.479945 0.000000 0.729792 0.478142 0.000000 0.740767 0.476333 0.000000 0.743538 0.504919 0.000000 0.746310 0.533504 0.000000
or the smaller CP is not 720 but 553
so the patches must be :
24 959 788 787 963
an his Uv :
0 553 788 720 960 (...) -
-
We'll get there gradually.
Can you send me the new model converted?
-
"
I'm not100% sure of the solution, but it seems it is necessary to indicate the opening of the patches.
The patches with 5 pointers are written with 5 CPS (but indicates with four segments in the bitfield)
For UVs, there is 4 CPs, but you have to indicate which are in thesegment that are not indicated in the bitfield." this is wrong.For the momment here is what I found about writing UV patches :
The first CP of each UV patches must be the smaller. (and be the number with the coordinates)
example:
5 249 1396 1394 837
0 92 483 281 200
0 1206 1655 1574 1206Is it the same for patches, must start with the smallest PC, careful not the one writing in patches, but the referent that carry the coordinates.
exemple
24 4 8 12 6
24 134 22 14 233 (if 134 is attached with a smaller CP than 14)
but I don't know if this is enough
-
I mean this :
Only Five pointers in this case can be patches when refreshed, alas
Your model have some "ghost patches" when refreshed.
You must used two or more splines to render this patches..
-
It is normal that some 3 and 4 pointer disappear. AM does not accept patches that are bypassed with the same spline. It is possible to write them but once refreshed, the AM's motor destroyed them.
I will see deeper for the UV. -
Yes it is true, no need hooks for convertion polygonal models
-
you're humble Nemyax! ... many have stopped along the way.
You are an important person for the AM community. (There are so few programmers.)
Thank you for making this work. This allowed me to better understand the patches. and understanding among other difficulties in automatically close 5 pointers in AM). But there is still a lot to discover in the writing of the AM format. (hooks ....)
Your work is a hope to bridge between the world of polygonal and that of AM. Thank you again. -
-
Thank for the models.
I'm not 100% sure of the solution, but it seems it is necessary to indicate the opening of the patches.
The patches with 5 pointers are written with 5 CPS (but indicates with four segments in the bitfield)
For UVs, there is 4 CPs, but you have to indicate which are in the segment that are not indicated in the bitfield. here EA -
Waow... nice result, nemyax.
Could you send me a simple example converted with your converter, I will try to see what is the problem with the UVs on five-pointers.
-
for writing patches :
If you follow the orientation and take the CP of the new spline at each crossing the bitfield is = the bitfield
if you use any CPs of each spline... the bitfield is = ( bitfield+ 5)
Let's talk about Polygons
in Open Forum
Posted
that's right nemyax, the Catmull Clark Subdivision works like this ... And I thought to do this at the start.
But from what I understand, a good topology includes 3.4 or 5 edges by vertices, hence the choice of topology of a hook in the first level of subdivision, after the rules of subdivisions will be classic.