Problem with Facehelper

Software: Away3D 4.x

Avatar
80prozent, Sr. Member
Posted: 19 August 2012 07:35 PM   Total Posts: 430

hi

i am trying to split faces using the FaceHelper.as.

when i try to use FaceHelper.triFaces or FaceHelper.quaterFaces on a simple primitive (plane) everything works fine, but if i try to use it on a imported mesh, it gives this error:

[Fault] exceptioninformation=RangeErrorError #3669: Bad input size. 

you can easily reproduce this error by adding this line to the “Intermediate_Head.as”, right after the headModel has been loadet:

FaceHelper.quarterFace(headModel00

i think the vertexTangentData and vertexNormalData are not changed by the Facehelper functions.

i am using a 2-week old zip-download of the master-branch

 

 

 

 Signature 

sorry…i hope my actionscript is better than my english…

   

Avatar
80prozent, Sr. Member
Posted: 19 August 2012 08:09 PM   Total Posts: 430   [ # 1 ]

Hi again

i solved the issue by changing the “updateSubGeometryData” inside of “FaceHelper.as” into this:

private static function updateSubGeometryData(subGeometry:SubGeometryvertices:Vector.<Number>, indices:Vector.<uint>, uvs:Vector.<Number>, normals:Vector.<Number> = nulltangents:Vector.<Number> = null):void
  {
   subGeometry
.updateVertexData(vertices);
   
subGeometry.updateIndexData(indices);
   
subGeometry.updateUVData(uvs);
   if (
normals{
    
if (normals.length != vertices.length{
     subGeometry
.autoDeriveVertexNormals true;
    
}
    
if (normals.length == vertices.length{
     subGeometry
.updateVertexNormalData(normals);
    
}
    
   }
   
if (tangents{
    
if (tangents.length != vertices.length{
     subGeometry
.autoDeriveVertexTangents true;
    
}
    
if (tangents.length == vertices.length{
     subGeometry
.updateVertexTangentData(tangents);
    
}
    
    
   }
  } 

i know that, this is only a quick fix, since all the normals- and tangentsdata gets lost.

 Signature 

sorry…i hope my actionscript is better than my english…

   

Richard Olsson, Administrator
Posted: 22 August 2012 07:03 AM   Total Posts: 1192   [ # 2 ]

Please file a bug report about this if you haven’t already.

   

Avatar
80prozent, Sr. Member
Posted: 22 August 2012 08:28 PM   Total Posts: 430   [ # 3 ]

i allready opened a new issue on git about this. you taged it as bug yourself.

https://github.com/away3d/away3d-core-fp11/issues/393

i am not very familiar with github, so please tell me if there is another bugreporting system i am not aware of.

anyway: thanks for all the hard work you are doing for this engine and community. answering all this threads must be almost a full-time job….

 Signature 

sorry…i hope my actionscript is better than my english…

   

Richard Olsson, Administrator
Posted: 23 August 2012 09:49 AM   Total Posts: 1192   [ # 4 ]

That’s why I said “if you haven’t already”. I remembered reading something like this in the bug tracker, but I wasn’t sure if it was yours. Thanks for reporting the issue. We’ll look into it when we get a chance!

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X