public void parseLogPackage(LogPackage logPack) {
}
- public void addData(final int frameNumber, int frameTime, boolean isError) {
- long fps = Math.round(TimelineConstants.KILO_LONG / (long) frameTime);
- String tooltipMessage = fps + " fps";
+ public void addData(final int frameNumber, int fps, boolean isError) {
+ double frameTime = (1 / (double) fps) * TimelineConstants.KILO_LONG;
+ String tooltipMessage = String.format("%.1f %s (%d fps)", frameTime, MS, fps);
if (isError) {
- frameTimeSeries.addSeriesItem(new DAChartSeriesItem(frameNumber,
- frameTime, ColorResources.RED, tooltipMessage, false));
+ frameTimeSeries.addSeriesItem(new DAChartSeriesItem(frameNumber, frameTime,
+ ColorResources.RED, tooltipMessage, false));
} else {
- frameTimeSeries.addSeriesItem(new DAChartSeriesItem(frameNumber,
- frameTime, tooltipMessage, false));
+ frameTimeSeries.addSeriesItem(new DAChartSeriesItem(frameNumber, frameTime,
+ tooltipMessage, false));
}
}
}