bugCal3D - 3d character animation library - Bugs: bug #8852, strange vertex translation in core...

Show feedback again

bug #8852: strange vertex translation in core submeshes

Submitted by:  None
Submitted on:  Wed Apr 4 12:23:20 2007  
Category: NoneSeverity: 3 - Normal
Priority: 5 - NormalStatus: None
Privacy: PublicAssigned to: None
Originator Email: -unavailable-Open/Closed: Closed

Add a New Comment (Rich MarkupRich Markup):

You are not logged in

Please log in, so followups can be emailed to you.


Wed Apr 4 12:23:20 2007, original submission:

I want to change a Cal3D hand model by scaling each finger segment. Each segment consists of vertices influenced by a bone.
My algorithm works in the following way:
At first I extend a bone and calculate the scale factor. After that I transform all vertices influenced by this bone into local coordinates. Then I multiply each vertex by the scale factor and cancel then the local transformation. I execute this course of events with each finger segment. The intention consists in adapting the finger lengths of each user in the current time. I use a data glove and transmit datas to the hand model.Thus I can virtually simulate a Cal3d hand model from each user.

I have following problem:
The are two possibilities to get all coordinates from each vertex of the submesh.
In the first example I use the CalModel and the CalRenderer:

file: submesh.txt

In this case I can't allocate a vertex to the influenced bone.
So I've to use the CalCoreSubmesh. There is a structure from "coresubmesh.h"

typedef struct
CalVector position;
CalVector normal;
std::vector<Influence> vectorInfluence;
int collapseId;
int faceCollapseCount;
} Vertex;

To get the values of the Vertex structure I only can do in the following way:

file: coresubmesh.txt

But the values of each vertex from the second procedure are different to the first procedure. The values of each vertex of the second procedure do not agree with the coordinates of the bones. There is a translation. I've found out that the translation is equal to the local translation of the first bone (r_wrist) from the file "skeleton.xsf". Manually I can add a translation vector on each vertex and then I have the right coordinates, which are equal to the bones. But that's dirty, because I want to use this procedure for other hand models.

How can I get the right coordinates of all vertices with influenced bones from the Core Submesh?



(Note: upload size limit is set to 1024 kB, after insertion of the required escape characters.)

Attach File(s):

Attached Files
file #2197:  Skeleton.XSF added by None (11kB - application/octet-stream)
file #2198:  coresubmesh.txt added by None (721B - text/plain)
file #2199:  submesh.txt added by None (933B - text/plain)


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by mp3butcher (Updated the item)
  • -unavailable- added by None (Submitted the item)

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.


    Error: not logged in



    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Wed Jan 21 20:13:55 2015mp3butcherOpen/ClosedOpen=>Closed
    Wed Apr 4 12:23:20 2007NoneAttached File-=>Added Skeleton.XSF, #2197
      Attached File-=>Added coresubmesh.txt, #2198
      Attached File-=>Added submesh.txt, #2199
    Show feedback again

    Back to the top

    Powered by Savane 3.1-cleanup