Page 5 of 138

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 3:08 am
by Veegie
Dan Frederiksen wrote:ajmiles, well maybe I'm reading too much into it and it might not be a problem in practice after the smoothing but I'm looking at the shaded veyron on page 3, particularly the flat wheel arch.
It seems there is an issue surrounding those areas in particular I've noticed.
Whether it is vertice inaccuracy or simply because the mesh isn't in quads I do not know.
But smoothing groups tend to get scary around those areas, too.

EDIT: You can see what I mean around the wheel arches here
Image

EDIT 2: Yup major issues
Image

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 5:34 am
by Ernegien
ajmiles wrote:Ernegien shouldn't have a problem fixing the flipped faces, I suspect it's just a case of not inverting the winding order every time he hits a triangle strip restart.

I'm not how easy it'll be to reconstitute the smoothing group information. Presumably smoothing groups exist so that vertices can be shared between polygons with different materials? (I think.) After the export to the vertex buffer has taken place any vertices that were shared were instead duplicated in each mesh that needed them. It may then be possible to find all the vertices that exist in more than 1 mesh, collapsed them into a single vertex and provide indices to which meshes/materials they belong?
So every other strip I am supposed to scan ahead and start backwards?

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 10:10 am
by ajmiles
Looking again at the sheer number of flipped faces (it looks like every other face is flipped, rather than just at strip restarts), it's more likely a case of not accounting for the fact that in a triangle strip the winding order inverts for every face drawn. So the first face will be clockwise, the second face is anti-clockwise, the third is clockwise, fourth is anti-clockwise etc. Try this, on alternate faces (either the odd or the even faces) output the indices in the "other" order. That is, if you had the faces (0,1,2), (1,2,3), (2,3,4), (4,5,6), try exporting this as (0,1,2), (1,3,2), (2,3,4), (4,6,5). So that the odd numbered faces are flipped.

If after doing that the entire car is culled, flip the even numbered faces.

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 2:09 pm
by Ernegien
ajmiles wrote:Looking again at the sheer number of flipped faces (it looks like every other face is flipped, rather than just at strip restarts), it's more likely a case of not accounting for the fact that in a triangle strip the winding order inverts for every face drawn. So the first face will be clockwise, the second face is anti-clockwise, the third is clockwise, fourth is anti-clockwise etc. Try this, on alternate faces (either the odd or the even faces) output the indices in the "other" order. That is, if you had the faces (0,1,2), (1,2,3), (2,3,4), (4,5,6), try exporting this as (0,1,2), (1,3,2), (2,3,4), (4,6,5). So that the odd numbered faces are flipped.

If after doing that the entire car is culled, flip the even numbered faces.
Yeah, everything is fixed now, thanks for the earlier tip :). Every odd face is flipped (first two index pairs swapped) and the winding restarts at each new strip.

strip: 012345
(0, 1, 2),(2, 1, 3),(2, 3 4),(4, 3, 5) etc...

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 2:47 pm
by Dan Frederiksen
veegie, nice. yes it does appear that fine detail on the main body can be deformed but doesn't look like a huge problem. perhaps try autosmoothing it all and render it with a polished material and an environment map with detail in. a reflective material will show perturbations much stronger than matte finish. car paint is shiny so it will need to pass that test somehow.

I've thought a bit about an algorithm to refine the positions but to do it really well it will have to be somewhat sophisticated. it will have to recognize large shapes, not just the n closest vertices. but doable at some level. it can be done.

Ernegien, was your nickname supposed to be Energien? : ) anyway, from veegie's picture it would appear the geometry is mirrored. if that's a general issue, not editor specific, you should perhaps invert x or y

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 3:14 pm
by Ernegien
Dan Frederiksen wrote:Ernegien, was your nickname supposed to be Energien? : )
It's supposed to signify reverse engineer :P

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 3:22 pm
by Dan Frederiksen
wouldn't that be reenigne then? :)

otherwise it's just a messed up engineer : )

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 3:29 pm
by Ernegien
Dan Frederiksen wrote:wouldn't that be reenigne then? :)

otherwise it's just a messed up engineer : )
"Byte"-swapped in pairs... lol

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 5:01 pm
by Simon
Can you Upload the new source if this fixed, please? :)

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 5:39 pm
by Ernegien
sommergemuese wrote:Can you Upload the new source if this fixed, please? :)

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 5:51 pm
by Simon
Wooow so great thanks 10000000 times :P

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 6:23 pm
by Veegie
Dan Frederiksen wrote:veegie, nice. yes it does appear that fine detail on the main body can be deformed but doesn't look like a huge problem. perhaps try autosmoothing it all and render it with a polished material and an environment map with detail in. a reflective material will show perturbations much stronger than matte finish. car paint is shiny so it will need to pass that test somehow.
Tried it.
Even with standard car paint, the lack of quads and the small-scale deformations lead to incorrect smoothing groups.

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 6:43 pm
by Dan Frederiksen
veegie, the material has nothing to do with smoothing groups. but a shiny material will more clearly show perturbation in a surface. you have to render it.
as for smoothing, just set the smoothing angle high enough until it takes. try 45 degrees for instance. or even 60. that's less important with regards to the vertex precision issue.

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 6:52 pm
by revelation
i currently don't have any data available to me other than the BMW files posted earlier in the thread, would it be possible to get some more sample files? i am trying to validate more of the things i have found so far.

Thanks in advance.

Re: [Xbox 360] Forza 3 Resource Extraction Tool (.carbin)

Posted: Fri Apr 09, 2010 7:42 pm
by Veegie
Dan Frederiksen wrote:veegie, the material has nothing to do with smoothing groups. but a shiny material will more clearly show perturbation in a surface. you have to render it.
as for smoothing, just set the smoothing angle high enough until it takes. try 45 degrees for instance. or even 60. that's less important with regards to the vertex precision issue.
Dan, I am quite familiar with modeling applications and their workings. I had only mentioned because it seemed that you were insinuating that the appropriate material was the end-all solution.
Though it may just have been a misinterpretation on my end.
The autosmoothing doesn't do any better with higher angles, it just spreads the issue to more areas.
The issue is not a lack of smoothing with autosmooth, the issue is incorrect smoothing, a direct derivative of the incorrect geometry.
As you know, autosmooth simply assigns smoothing groups and tells the program, "This is smooth. This face is not.".
The problem is that when they creased their edges to smooth them out (from a geometry standpoint), the inaccuracy issue that we're facing is messing up the edge loops that go throughout that crease. This in turn causes the smoothing to mess up. No matter how you go about it, if you assign any combination of smoothing groups to those trouble-regions, it will look incorrect (as pictured previously).
We're just going to have to wait until the issue is cleared up.
revelation wrote:i currently don't have any data available to me other than the BMW files posted earlier in the thread, would it be possible to get some more sample files? i am trying to validate more of the things i have found so far.

Thanks in advance.
I can put a few more files on my server when I get home from the office if you'd like.