Пример #1
0
        // Called every frame. 'delta' is the elapsed time since the previous frame.
        public override void _Process(float delta)
        {
            ProfilingCollection.add("frame");

            ProfilingCollection.ProcessTime(delta);

            foreach (KeyValuePair <string, Metric> entry in ProfilingCollection.values)
            {
                var metric = entry.Value;

                //var labels = valueLabels2[entry.Key];
                //labels[0].Text = "" + metric.currentSum();
                //labels[1].Text = "" + metric.currentInterval();

                var metricData = valueLabels[entry.Key];
                metricData.labels[0].Text = "" + metric.currentSum();
                metricData.labels[1].Text = "" + metric.currentInterval();
                this.graphControl.AddMetricPoint(metricData.graphIndex, new Vector2(frameCount, (float)metric.currentInterval()));
            }

            frameCount++;
        }
Пример #2
0
 public void OnEntry()
 {
     ProfilingCollection.add(className + "." + methodeName);
 }