{
char buf[100];
- sprintf(buf, "%.3f s", (1.0 * f.numerator) / f.denominator);
+ sprintf(buf, "%.3f", (1.0 * f.numerator) / f.denominator);
return buf;
}
{
char buf[100];
- sprintf(buf, "%.3f fps", (1.0 * f.denominator) / f.numerator);
+ sprintf(buf, "%.3f", (1.0 * f.denominator) / f.numerator);
return buf;
}
{
printf("%s\tInterval: %s ", prefix, frmtype2s(frmival.type).c_str());
if (frmival.type == V4L2_FRMIVAL_TYPE_DISCRETE) {
- printf("%s (%s)\n", fract2sec(frmival.discrete).c_str(),
+ printf("%ss (%s fps)\n", fract2sec(frmival.discrete).c_str(),
fract2fps(frmival.discrete).c_str());
} else if (frmival.type == V4L2_FRMIVAL_TYPE_STEPWISE) {
- printf("%s - %s with step %s\n",
+ printf("%ss - %ss with step %ss (%s-%s fps)\n",
fract2sec(frmival.stepwise.min).c_str(),
fract2sec(frmival.stepwise.max).c_str(),
- fract2sec(frmival.stepwise.step).c_str());
- printf("%s\t : ", prefix);
- printf("(%s - %s with step %s)\n",
- fract2fps(frmival.stepwise.min).c_str(),
+ fract2sec(frmival.stepwise.step).c_str(),
fract2fps(frmival.stepwise.max).c_str(),
- fract2fps(frmival.stepwise.step).c_str());
+ fract2fps(frmival.stepwise.min).c_str());
}
}