initial commit
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
#include "ChronoReading.h"
|
||||
#include "ChronoProfile.h"
|
||||
|
||||
|
||||
// Constructor implementation
|
||||
ChronoReading::ChronoReading(){}
|
||||
ChronoReading::ChronoReading(int fps, ChronoProfile profile) {
|
||||
_fps=fps;
|
||||
_profile=profile;
|
||||
}
|
||||
ChronoProfile ChronoReading::getProfile(){return _profile;}
|
||||
int ChronoReading::getFPS(){
|
||||
return _fps;
|
||||
}
|
||||
int ChronoReading::getFPE(){
|
||||
float weight=_profile.getProjectileProfile().getWeight();
|
||||
return (int)round(_calculateFPE(_fps, weight));
|
||||
}
|
||||
float ChronoReading::_calculateFPE(float fps, float weight){
|
||||
//weight in grains
|
||||
return (fps*fps*weight) / 450240;
|
||||
}
|
||||
Reference in New Issue
Block a user