bugCal3D - 3d character animation library - Bugs: bug #18045, Tangent space calculation does not...

 
 
Show feedback again

bug #18045: Tangent space calculation does not include cross factor

Submitted by:  Peter Amstutz <tetron>
Submitted on:  Mon 18 Apr 2011 03:19:17 PM UTC  
 
Category: NoneSeverity: 3 - Normal
Priority: 5 - NormalStatus: None
Privacy: PublicAssigned to: None
Open/Closed: Open

Add a New Comment (Rich MarkupRich Markup):
   

You are not logged in

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

 

Mon 18 Apr 2011 03:19:17 PM UTC, original submission:

When calculating the tangent space basis (required for normal mapping), Cal3D does not set the cross factor. The cross factor is necessary to prevent inverted tangent spaces in areas where the texture map is reused and/or reverses direction.

Attached is a modified CalCoreSubmesh that correctly calculates the cross factor. The functions of interest are:

void CalCoreSubmesh::UpdateTangentVector(int v0, int v1, int v2, int mapId, std::vector<CalVector>& bitangents);

bool CalCoreSubmesh::enableTangents(int mapId, bool enabled);

Peter Amstutz <tetron>

 

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

Attach File(s):
   
   
Comment:
   

Attached Files
file #12881:  coresubmesh.cpp added by tetron (25kB - text/plain)
file #12882:  coresubmesh.h added by tetron (4kB - text/plain)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by tetron (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.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 2 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Mon 18 Apr 2011 03:19:17 PM UTCtetronAttached File-=>Added coresubmesh.cpp, #12881
      Attached File-=>Added coresubmesh.h, #12882
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup