Fabrice3D

If you got the time, could you share more optimizations?

I hadn't a clue about merge or maxpolyfilter

Cheers

On Nov 23, 7:54 pm, Fabrice3D <[email protected]> wrote:
> Hi wsdmeer
>
> the Merge class is very easy to setup:
>
> import away3d.geom.Merge;
>
> ///make instance
> var merge:Merge = new Merge(false, false, false);
>
> params:
> [optional] Boolean. Defines if mesh2 is merge using its objectspace or  
> worldspace. Default is true.
> means that the position in space of the to be merged mesh is taken in  
> account or not
>
> [optional] Boolean. Defines if the receiver object must generate new  
> vertexes, uv's or uses mesh2's. Default is false.
> if some vertexes/uvs are shared or saved somehwere else, setting to  
> true prevents conflicts or null objects. if true
> the to be merged object is copied during parsing and merged to  
> reciever object with new instances of vertexes and uv's
>
> [optional] Boolean. Defines if the receiver object must use the mesh2  
> material information. If false the merge information from mesh2 gets  
> the mesh1 material. Default is false.
> in your case, you probably want that the houses become one object but  
> ypu want they keep there visual differences by keeping their material  
> refferences
>
> merge.apply(mesh1, mesh2);
> mesh1 = receiver mesh
> mesh2 = to be merged mesh to mesh 1
>
> so your "house" loop would look in pseudo code like this
> say you have 4 houses, you pick the first one as receiver.
>
> var merge:Merge = new Merge(true, true, true);
>
> var houses:Array = [house1, house2, house3];
>
> loop over houses
>         merge.apply(house0, houses[index]);
>
> if you addChild house0, its now a single mesh looking exactly as all  
> your houses
> you can now get rid of all other houses elements.
>
> Fabrice
>
> On Nov 23, 2009, at 9:05 AM, wsvdmeer wrote:
>
>
>
> > Hey Fabrice,
>
> > The i gave the 3d modeller here the task at removing the faces and i'm
> > going to generate new maps with Prefab.
> > Do you have an example on how to use the merge class?
> > And thanks for your time and help!
>
> > On 19 nov, 21:55, Fabrice3D <[email protected]> wrote:
> >> There is a maxpolygon filter. that you might consider
> >> and i do not know if its the case for all houses, but on your house
> >> model, the floor could be deleted and same for backside
> >> and you also could imporve the maps. Not that they are not lovely but
> >> they are not using the full area of the map, and they should be
> >> brought back to 512x512 max, especially with this amount of houses.
>
> >> Another trick is to use for your city the Merge class, so all object
> >> level calculations would be executed only once...
>
> >> there are of course more ways to optimize, but these should bring you
> >> on the right path.
>
> >> Fabrice
>
> >> On Nov 19, 2009, at 4:55 PM, wsvdmeer wrote:
>
> >>> I'm working on a project that shows a street with around 43 houses
> >>> i've optimized a lot with the loading, textrures and filesize but  
> >>> i'm
> >>> running into a problem with the maximum polygon count.
>
> >>> Here are the demos :
>
> >>> MD2 files:  http://labs.speak.nl/3d/away3d/demo20/bin/
> >>> AWD files:http://labs.speak.nl/3d/away3d/demo21/bin/
>
> >>> (Press 1 for firstperson view 2 for birdview 3 for 3rd person view)
>
> >>> If you look at multiple houses (3000+/4000+) the framerate drops.
> >>> Are there any workarounds/tricks for this?
>
> >>> Or should i switch to Away3dLite?

Reply via email to