Shipper like UPS or DHL use mass weight rate and volumetric weight rate
The attachment file do the calculation for both.
Then a function compare the two rate and choose the higher value beetwenn them.
Just be carefull you must write in the file the same name that you book when you create a new shipper in the admin
;D
Soory the attchment file
[attachment cleanup by admin]