forked from qt-creator/qt-creator
QmlProfiler: Rename QmlEvent::startTime to "timestamp"
As many events are instantaneous and we're going to drop the duration property soon, this is more fitting. Change-Id: I6e13dd076a5b9df16aed44bf9f631ea5760e9cbf Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
This commit is contained in:
@@ -109,10 +109,10 @@ void DebugMessagesModel::loadData()
|
|||||||
|
|
||||||
foreach (const QmlEvent &event, simpleModel->events()) {
|
foreach (const QmlEvent &event, simpleModel->events()) {
|
||||||
const QmlEventType &type = types[event.typeIndex()];
|
const QmlEventType &type = types[event.typeIndex()];
|
||||||
if (!accepted(type) || event.startTime() < 0)
|
if (!accepted(type) || event.timestamp() < 0)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
m_data.insert(insert(event.startTime(), 0, type.detailType),
|
m_data.insert(insert(event.timestamp(), 0, type.detailType),
|
||||||
MessageData(event.stringData(), event.typeIndex()));
|
MessageData(event.stringData(), event.typeIndex()));
|
||||||
if (type.detailType > m_maximumMsgType)
|
if (type.detailType > m_maximumMsgType)
|
||||||
m_maximumMsgType = event.typeIndex();
|
m_maximumMsgType = event.typeIndex();
|
||||||
|
@@ -119,14 +119,14 @@ void FlameGraphModel::loadData(qint64 rangeStart, qint64 rangeEnd)
|
|||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (checkRanges) {
|
if (checkRanges) {
|
||||||
if ((event->startTime() + event->duration() < rangeStart)
|
if ((event->timestamp() + event->duration() < rangeStart)
|
||||||
|| (event->startTime() > rangeEnd))
|
|| (event->timestamp() > rangeEnd))
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
const QmlEvent *potentialParent = callStack.top();
|
const QmlEvent *potentialParent = callStack.top();
|
||||||
while (potentialParent &&
|
while (potentialParent &&
|
||||||
potentialParent->startTime() + potentialParent->duration() <= event->startTime()) {
|
potentialParent->timestamp() + potentialParent->duration() <= event->timestamp()) {
|
||||||
callStack.pop();
|
callStack.pop();
|
||||||
stackTop = stackTop->parent;
|
stackTop = stackTop->parent;
|
||||||
potentialParent = callStack.top();
|
potentialParent = callStack.top();
|
||||||
|
@@ -152,7 +152,7 @@ void InputEventsModel::loadData()
|
|||||||
if (!accepted(type))
|
if (!accepted(type))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
m_data.insert(insert(event.startTime(), 0, type.detailType),
|
m_data.insert(insert(event.timestamp(), 0, type.detailType),
|
||||||
InputEvent(static_cast<InputEventType>(event.numericData(0)),
|
InputEvent(static_cast<InputEventType>(event.numericData(0)),
|
||||||
event.numericData(1), event.numericData(2)));
|
event.numericData(1), event.numericData(2)));
|
||||||
|
|
||||||
|
@@ -162,12 +162,12 @@ void MemoryUsageModel::loadData()
|
|||||||
const QVector<QmlEventType> &types = simpleModel->eventTypes();
|
const QVector<QmlEventType> &types = simpleModel->eventTypes();
|
||||||
foreach (const QmlEvent &event, simpleModel->events()) {
|
foreach (const QmlEvent &event, simpleModel->events()) {
|
||||||
const QmlEventType &type = types[event.typeIndex()];
|
const QmlEventType &type = types[event.typeIndex()];
|
||||||
while (!rangeStack.empty() && rangeStack.top().endTime < event.startTime())
|
while (!rangeStack.empty() && rangeStack.top().endTime < event.timestamp())
|
||||||
rangeStack.pop();
|
rangeStack.pop();
|
||||||
if (!accepted(type)) {
|
if (!accepted(type)) {
|
||||||
if (type.rangeType != MaximumRangeType) {
|
if (type.rangeType != MaximumRangeType) {
|
||||||
rangeStack.push(RangeStackFrame(event.typeIndex(), event.startTime(),
|
rangeStack.push(RangeStackFrame(event.typeIndex(), event.timestamp(),
|
||||||
event.startTime() + event.duration()));
|
event.timestamp() + event.duration()));
|
||||||
}
|
}
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
@@ -187,9 +187,9 @@ void MemoryUsageModel::loadData()
|
|||||||
|
|
||||||
if (currentUsageIndex != -1) {
|
if (currentUsageIndex != -1) {
|
||||||
insertEnd(currentUsageIndex,
|
insertEnd(currentUsageIndex,
|
||||||
event.startTime() - startTime(currentUsageIndex) - 1);
|
event.timestamp() - startTime(currentUsageIndex) - 1);
|
||||||
}
|
}
|
||||||
currentUsageIndex = insertStart(event.startTime(), SmallItem);
|
currentUsageIndex = insertStart(event.timestamp(), SmallItem);
|
||||||
m_data.insert(currentUsageIndex, allocation);
|
m_data.insert(currentUsageIndex, allocation);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -212,8 +212,8 @@ void MemoryUsageModel::loadData()
|
|||||||
m_maxSize = currentSize;
|
m_maxSize = currentSize;
|
||||||
if (currentJSHeapIndex != -1)
|
if (currentJSHeapIndex != -1)
|
||||||
insertEnd(currentJSHeapIndex,
|
insertEnd(currentJSHeapIndex,
|
||||||
event.startTime() - startTime(currentJSHeapIndex) - 1);
|
event.timestamp() - startTime(currentJSHeapIndex) - 1);
|
||||||
currentJSHeapIndex = insertStart(event.startTime(), type.detailType);
|
currentJSHeapIndex = insertStart(event.timestamp(), type.detailType);
|
||||||
m_data.insert(currentJSHeapIndex, allocation);
|
m_data.insert(currentJSHeapIndex, allocation);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -182,7 +182,7 @@ void PixmapCacheModel::loadData()
|
|||||||
|
|
||||||
PixmapCacheItem newEvent;
|
PixmapCacheItem newEvent;
|
||||||
newEvent.pixmapEventType = static_cast<PixmapEventType>(type.detailType);
|
newEvent.pixmapEventType = static_cast<PixmapEventType>(type.detailType);
|
||||||
qint64 pixmapStartTime = event.startTime();
|
qint64 pixmapStartTime = event.timestamp();
|
||||||
|
|
||||||
newEvent.urlIndex = -1;
|
newEvent.urlIndex = -1;
|
||||||
for (QVector<Pixmap>::const_iterator it(m_pixmaps.cend()); it != m_pixmaps.cbegin();) {
|
for (QVector<Pixmap>::const_iterator it(m_pixmaps.cend()); it != m_pixmaps.cbegin();) {
|
||||||
@@ -232,7 +232,7 @@ void PixmapCacheModel::loadData()
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case PixmapCacheCountChanged: {// Cache Size Changed Event
|
case PixmapCacheCountChanged: {// Cache Size Changed Event
|
||||||
pixmapStartTime = event.startTime() + 1; // delay 1 ns for proper sorting
|
pixmapStartTime = event.timestamp() + 1; // delay 1 ns for proper sorting
|
||||||
|
|
||||||
bool uncache = cumulatedCount > event.numericData(2);
|
bool uncache = cumulatedCount > event.numericData(2);
|
||||||
cumulatedCount = event.numericData(2);
|
cumulatedCount = event.numericData(2);
|
||||||
@@ -348,7 +348,7 @@ void PixmapCacheModel::loadData()
|
|||||||
}
|
}
|
||||||
|
|
||||||
PixmapState &state = pixmap.sizes[newEvent.sizeIndex];
|
PixmapState &state = pixmap.sizes[newEvent.sizeIndex];
|
||||||
// If the pixmap loading wasn't started, start it at traceStartTime()
|
// If the pixmap loading wasn't started, start it at tracetimestamp()
|
||||||
if (state.loadState == Initial) {
|
if (state.loadState == Initial) {
|
||||||
newEvent.pixmapEventType = PixmapLoadingStarted;
|
newEvent.pixmapEventType = PixmapLoadingStarted;
|
||||||
newEvent.typeId = event.typeIndex();
|
newEvent.typeId = event.typeIndex();
|
||||||
|
@@ -29,10 +29,10 @@
|
|||||||
namespace QmlProfiler {
|
namespace QmlProfiler {
|
||||||
|
|
||||||
struct QmlEvent {
|
struct QmlEvent {
|
||||||
QmlEvent(qint64 startTime = -1, qint64 duration = -1, int typeIndex = -1,
|
QmlEvent(qint64 timestamp = -1, qint64 duration = -1, int typeIndex = -1,
|
||||||
qint64 num0 = 0, qint64 num1 = 0, qint64 num2 = 0, qint64 num3 = 0,
|
qint64 num0 = 0, qint64 num1 = 0, qint64 num2 = 0, qint64 num3 = 0,
|
||||||
qint64 num4 = 0) :
|
qint64 num4 = 0) :
|
||||||
m_startTime(startTime), m_duration(duration), m_dataType(NumericData),
|
m_timestamp(timestamp), m_duration(duration), m_dataType(NumericData),
|
||||||
m_typeIndex(typeIndex)
|
m_typeIndex(typeIndex)
|
||||||
{
|
{
|
||||||
m_numericData[0] = num0;
|
m_numericData[0] = num0;
|
||||||
@@ -42,14 +42,14 @@ struct QmlEvent {
|
|||||||
m_numericData[4] = num4;
|
m_numericData[4] = num4;
|
||||||
}
|
}
|
||||||
|
|
||||||
QmlEvent(qint64 startTime, qint64 duration, int typeIndex, const QString &data)
|
QmlEvent(qint64 timestamp, qint64 duration, int typeIndex, const QString &data)
|
||||||
: m_startTime(startTime), m_duration(duration), m_typeIndex(typeIndex)
|
: m_timestamp(timestamp), m_duration(duration), m_typeIndex(typeIndex)
|
||||||
{
|
{
|
||||||
assignStringData(data);
|
assignStringData(data);
|
||||||
}
|
}
|
||||||
|
|
||||||
QmlEvent(const QmlEvent &other) :
|
QmlEvent(const QmlEvent &other) :
|
||||||
m_startTime(other.m_startTime), m_duration(other.m_duration),
|
m_timestamp(other.m_timestamp), m_duration(other.m_duration),
|
||||||
m_dataType(other.m_dataType), m_typeIndex(other.m_typeIndex)
|
m_dataType(other.m_dataType), m_typeIndex(other.m_typeIndex)
|
||||||
{
|
{
|
||||||
assignData(other);
|
assignData(other);
|
||||||
@@ -61,7 +61,7 @@ struct QmlEvent {
|
|||||||
if (m_dataType == StringData)
|
if (m_dataType == StringData)
|
||||||
delete m_stringData;
|
delete m_stringData;
|
||||||
|
|
||||||
m_startTime = other.m_startTime;
|
m_timestamp = other.m_timestamp;
|
||||||
m_duration = other.m_duration;
|
m_duration = other.m_duration;
|
||||||
m_typeIndex = other.m_typeIndex;
|
m_typeIndex = other.m_typeIndex;
|
||||||
m_dataType = other.m_dataType;
|
m_dataType = other.m_dataType;
|
||||||
@@ -76,8 +76,8 @@ struct QmlEvent {
|
|||||||
delete m_stringData;
|
delete m_stringData;
|
||||||
}
|
}
|
||||||
|
|
||||||
qint64 startTime() const { return m_startTime; }
|
qint64 timestamp() const { return m_timestamp; }
|
||||||
void setStartTime(qint64 startTime) { m_startTime = startTime; }
|
void setTimestamp(qint64 timestamp) { m_timestamp = timestamp; }
|
||||||
|
|
||||||
qint64 duration() const { return m_duration; }
|
qint64 duration() const { return m_duration; }
|
||||||
void setDuration(qint64 duration) { m_duration = duration; }
|
void setDuration(qint64 duration) { m_duration = duration; }
|
||||||
@@ -114,7 +114,7 @@ struct QmlEvent {
|
|||||||
|
|
||||||
bool isValid() const
|
bool isValid() const
|
||||||
{
|
{
|
||||||
return m_startTime != -1;
|
return m_timestamp != -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
@@ -122,7 +122,7 @@ private:
|
|||||||
static const quint8 StringData = 254;
|
static const quint8 StringData = 254;
|
||||||
static const quint8 NumericData = 255;
|
static const quint8 NumericData = 255;
|
||||||
|
|
||||||
qint64 m_startTime;
|
qint64 m_timestamp;
|
||||||
qint64 m_duration;
|
qint64 m_duration;
|
||||||
union {
|
union {
|
||||||
qint64 m_numericData[5];
|
qint64 m_numericData[5];
|
||||||
|
@@ -84,10 +84,10 @@ void QmlProfilerAnimationsModel::loadData()
|
|||||||
qint64 estimatedDuration = event.numericData(0) > 0 ? 1e9/event.numericData(0) : 1;
|
qint64 estimatedDuration = event.numericData(0) > 0 ? 1e9/event.numericData(0) : 1;
|
||||||
|
|
||||||
// the profiler registers the animation events at the end of them
|
// the profiler registers the animation events at the end of them
|
||||||
qint64 realEndTime = event.startTime();
|
qint64 realEndTime = event.timestamp();
|
||||||
|
|
||||||
// ranges should not overlap. If they do, our estimate wasn't accurate enough
|
// ranges should not overlap. If they do, our estimate wasn't accurate enough
|
||||||
qint64 realStartTime = qMax(event.startTime() - estimatedDuration,
|
qint64 realStartTime = qMax(event.timestamp() - estimatedDuration,
|
||||||
minNextStartTimes[lastThread]);
|
minNextStartTimes[lastThread]);
|
||||||
|
|
||||||
// Sometimes our estimate is far off or the server has miscalculated the frame rate
|
// Sometimes our estimate is far off or the server has miscalculated the frame rate
|
||||||
@@ -109,7 +109,7 @@ void QmlProfilerAnimationsModel::loadData()
|
|||||||
m_maxRenderThreadAnimations = qMax(lastEvent.animationcount,
|
m_maxRenderThreadAnimations = qMax(lastEvent.animationcount,
|
||||||
m_maxRenderThreadAnimations);
|
m_maxRenderThreadAnimations);
|
||||||
|
|
||||||
minNextStartTimes[lastThread] = event.startTime() + 1;
|
minNextStartTimes[lastThread] = event.timestamp() + 1;
|
||||||
|
|
||||||
updateProgress(count(), referenceList.count());
|
updateProgress(count(), referenceList.count());
|
||||||
}
|
}
|
||||||
|
@@ -174,7 +174,7 @@ bool QmlProfilerDataModel::isEmpty() const
|
|||||||
|
|
||||||
inline static bool operator<(const QmlEvent &t1, const QmlEvent &t2)
|
inline static bool operator<(const QmlEvent &t1, const QmlEvent &t2)
|
||||||
{
|
{
|
||||||
return t1.startTime() < t2.startTime();
|
return t1.timestamp() < t2.timestamp();
|
||||||
}
|
}
|
||||||
|
|
||||||
inline static uint qHash(const QmlEventType &type)
|
inline static uint qHash(const QmlEventType &type)
|
||||||
@@ -271,7 +271,7 @@ qint64 QmlProfilerDataModel::lastTimeMark() const
|
|||||||
if (d->eventList.isEmpty())
|
if (d->eventList.isEmpty())
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
return d->eventList.last().startTime() + d->eventList.last().duration();
|
return d->eventList.last().timestamp() + d->eventList.last().duration();
|
||||||
}
|
}
|
||||||
|
|
||||||
void QmlProfilerDataModel::detailsChanged(int requestId, const QString &newString)
|
void QmlProfilerDataModel::detailsChanged(int requestId, const QString &newString)
|
||||||
|
@@ -77,7 +77,7 @@ void QmlProfilerRangeModel::loadData()
|
|||||||
continue;
|
continue;
|
||||||
|
|
||||||
// store starttime-based instance
|
// store starttime-based instance
|
||||||
m_data.insert(insert(event.startTime(), event.duration(), event.typeIndex()),
|
m_data.insert(insert(event.timestamp(), event.duration(), event.typeIndex()),
|
||||||
QmlRangeEventStartInstance());
|
QmlRangeEventStartInstance());
|
||||||
updateProgress(count(), eventList.count() * 5);
|
updateProgress(count(), eventList.count() * 5);
|
||||||
}
|
}
|
||||||
|
@@ -188,8 +188,8 @@ void QmlProfilerStatisticsModel::loadData(qint64 rangeStart, qint64 rangeEnd)
|
|||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (checkRanges) {
|
if (checkRanges) {
|
||||||
if ((event->startTime() + event->duration() < rangeStart)
|
if ((event->timestamp() + event->duration() < rangeStart)
|
||||||
|| (event->startTime() > rangeEnd))
|
|| (event->timestamp() > rangeEnd))
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -208,17 +208,17 @@ void QmlProfilerStatisticsModel::loadData(qint64 rangeStart, qint64 rangeEnd)
|
|||||||
durations[event->typeIndex()].append(event->duration());
|
durations[event->typeIndex()].append(event->duration());
|
||||||
|
|
||||||
// qml time computation
|
// qml time computation
|
||||||
if (event->startTime() > lastEndTime) { // assume parent event if starts before last end
|
if (event->timestamp() > lastEndTime) { // assume parent event if starts before last end
|
||||||
qmlTime += event->duration();
|
qmlTime += event->duration();
|
||||||
lastEndTime = event->startTime() + event->duration();
|
lastEndTime = event->timestamp() + event->duration();
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
// binding loop detection
|
// binding loop detection
|
||||||
//
|
//
|
||||||
const QmlEvent *potentialParent = callStack.top();
|
const QmlEvent *potentialParent = callStack.top();
|
||||||
while (potentialParent && !(potentialParent->startTime() + potentialParent->duration() >
|
while (potentialParent && !(potentialParent->timestamp() + potentialParent->duration() >
|
||||||
event->startTime())) {
|
event->timestamp())) {
|
||||||
callStack.pop();
|
callStack.pop();
|
||||||
potentialParent = callStack.top();
|
potentialParent = callStack.top();
|
||||||
}
|
}
|
||||||
@@ -362,14 +362,14 @@ void QmlProfilerStatisticsParentsModel::loadData()
|
|||||||
continue;
|
continue;
|
||||||
|
|
||||||
// level computation
|
// level computation
|
||||||
if (endtimesPerLevel[level] > event.startTime()) {
|
if (endtimesPerLevel[level] > event.timestamp()) {
|
||||||
level++;
|
level++;
|
||||||
} else {
|
} else {
|
||||||
while (level > Constants::QML_MIN_LEVEL &&
|
while (level > Constants::QML_MIN_LEVEL &&
|
||||||
endtimesPerLevel[level-1] <= event.startTime())
|
endtimesPerLevel[level-1] <= event.timestamp())
|
||||||
level--;
|
level--;
|
||||||
}
|
}
|
||||||
endtimesPerLevel[level] = event.startTime() + event.duration();
|
endtimesPerLevel[level] = event.timestamp() + event.duration();
|
||||||
|
|
||||||
int parentTypeIndex = -1;
|
int parentTypeIndex = -1;
|
||||||
if (level > Constants::QML_MIN_LEVEL && lastParent.contains(level-1))
|
if (level > Constants::QML_MIN_LEVEL && lastParent.contains(level-1))
|
||||||
@@ -424,14 +424,14 @@ void QmlProfilerStatisticsChildrenModel::loadData()
|
|||||||
continue;
|
continue;
|
||||||
|
|
||||||
// level computation
|
// level computation
|
||||||
if (endtimesPerLevel[level] > event.startTime()) {
|
if (endtimesPerLevel[level] > event.timestamp()) {
|
||||||
level++;
|
level++;
|
||||||
} else {
|
} else {
|
||||||
while (level > Constants::QML_MIN_LEVEL &&
|
while (level > Constants::QML_MIN_LEVEL &&
|
||||||
endtimesPerLevel[level-1] <= event.startTime())
|
endtimesPerLevel[level-1] <= event.timestamp())
|
||||||
level--;
|
level--;
|
||||||
}
|
}
|
||||||
endtimesPerLevel[level] = event.startTime() + event.duration();
|
endtimesPerLevel[level] = event.timestamp() + event.duration();
|
||||||
|
|
||||||
int parentId = -1;
|
int parentId = -1;
|
||||||
|
|
||||||
|
@@ -369,7 +369,7 @@ void QmlProfilerFileReader::loadEvents(QXmlStreamReader &stream)
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
event.setStartTime(attributes.value(_("startTime")).toLongLong());
|
event.setTimestamp(attributes.value(_("startTime")).toLongLong());
|
||||||
if (attributes.hasAttribute(_("duration")))
|
if (attributes.hasAttribute(_("duration")))
|
||||||
event.setDuration(attributes.value(_("duration")).toLongLong());
|
event.setDuration(attributes.value(_("duration")).toLongLong());
|
||||||
|
|
||||||
@@ -591,14 +591,13 @@ void QmlProfilerFileWriter::save(QIODevice *device)
|
|||||||
const QmlEvent &event = m_events[rangeIndex];
|
const QmlEvent &event = m_events[rangeIndex];
|
||||||
|
|
||||||
stream.writeStartElement(_("range"));
|
stream.writeStartElement(_("range"));
|
||||||
stream.writeAttribute(_("startTime"), QString::number(event.startTime()));
|
stream.writeAttribute(_("startTime"), QString::number(event.timestamp()));
|
||||||
if (event.duration() > 0) // no need to store duration of instantaneous events
|
if (event.duration() > 0) // no need to store duration of instantaneous events
|
||||||
stream.writeAttribute(_("duration"), QString::number(event.duration()));
|
stream.writeAttribute(_("duration"), QString::number(event.duration()));
|
||||||
stream.writeAttribute(_("eventIndex"), QString::number(event.typeIndex()));
|
stream.writeAttribute(_("eventIndex"), QString::number(event.typeIndex()));
|
||||||
|
|
||||||
const QmlEventType &type = m_eventTypes[event.typeIndex()];
|
const QmlEventType &type = m_eventTypes[event.typeIndex()];
|
||||||
|
|
||||||
|
|
||||||
if (type.message == Event) {
|
if (type.message == Event) {
|
||||||
if (type.detailType == AnimationFrame) {
|
if (type.detailType == AnimationFrame) {
|
||||||
// special: animation event
|
// special: animation event
|
||||||
|
@@ -150,7 +150,7 @@ void SceneGraphTimelineModel::loadData()
|
|||||||
// look incomplete if that was left out as the printf profiler lists it, too, and people
|
// look incomplete if that was left out as the printf profiler lists it, too, and people
|
||||||
// are apparently comparing that. Unfortunately it is somewhat redundant as the other
|
// are apparently comparing that. Unfortunately it is somewhat redundant as the other
|
||||||
// parts of the breakdown are usually very short.
|
// parts of the breakdown are usually very short.
|
||||||
qint64 startTime = event.startTime() - event.numericData(0) - event.numericData(1) -
|
qint64 startTime = event.timestamp() - event.numericData(0) - event.numericData(1) -
|
||||||
event.numericData(2) - event.numericData(3);
|
event.numericData(2) - event.numericData(3);
|
||||||
startTime += insert(startTime, event.numericData(0), event.typeIndex(), RenderPreprocess);
|
startTime += insert(startTime, event.numericData(0), event.typeIndex(), RenderPreprocess);
|
||||||
startTime += insert(startTime, event.numericData(1), event.typeIndex(), RenderUpdate);
|
startTime += insert(startTime, event.numericData(1), event.typeIndex(), RenderUpdate);
|
||||||
@@ -159,19 +159,19 @@ void SceneGraphTimelineModel::loadData()
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case SceneGraphAdaptationLayerFrame: {
|
case SceneGraphAdaptationLayerFrame: {
|
||||||
qint64 startTime = event.startTime() - event.numericData(1) - event.numericData(2);
|
qint64 startTime = event.timestamp() - event.numericData(1) - event.numericData(2);
|
||||||
startTime += insert(startTime, event.numericData(1), event.typeIndex(), GlyphRender,
|
startTime += insert(startTime, event.numericData(1), event.typeIndex(), GlyphRender,
|
||||||
event.numericData(0));
|
event.numericData(0));
|
||||||
insert(startTime, event.numericData(2), event.typeIndex(), GlyphStore, event.numericData(0));
|
insert(startTime, event.numericData(2), event.typeIndex(), GlyphStore, event.numericData(0));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case SceneGraphContextFrame: {
|
case SceneGraphContextFrame: {
|
||||||
insert(event.startTime() - event.numericData(0), event.numericData(0), event.typeIndex(),
|
insert(event.timestamp() - event.numericData(0), event.numericData(0), event.typeIndex(),
|
||||||
Material);
|
Material);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case SceneGraphRenderLoopFrame: {
|
case SceneGraphRenderLoopFrame: {
|
||||||
qint64 startTime = event.startTime() - event.numericData(0) - event.numericData(1) -
|
qint64 startTime = event.timestamp() - event.numericData(0) - event.numericData(1) -
|
||||||
event.numericData(2);
|
event.numericData(2);
|
||||||
startTime += insert(startTime, event.numericData(0), event.typeIndex(),
|
startTime += insert(startTime, event.numericData(0), event.typeIndex(),
|
||||||
RenderThreadSync);
|
RenderThreadSync);
|
||||||
@@ -181,7 +181,7 @@ void SceneGraphTimelineModel::loadData()
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case SceneGraphTexturePrepare: {
|
case SceneGraphTexturePrepare: {
|
||||||
qint64 startTime = event.startTime() - event.numericData(0) - event.numericData(1) -
|
qint64 startTime = event.timestamp() - event.numericData(0) - event.numericData(1) -
|
||||||
event.numericData(2) - event.numericData(3) - event.numericData(4);
|
event.numericData(2) - event.numericData(3) - event.numericData(4);
|
||||||
startTime += insert(startTime, event.numericData(0), event.typeIndex(), TextureBind);
|
startTime += insert(startTime, event.numericData(0), event.typeIndex(), TextureBind);
|
||||||
startTime += insert(startTime, event.numericData(1), event.typeIndex(), TextureConvert);
|
startTime += insert(startTime, event.numericData(1), event.typeIndex(), TextureConvert);
|
||||||
@@ -191,12 +191,12 @@ void SceneGraphTimelineModel::loadData()
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case SceneGraphTextureDeletion: {
|
case SceneGraphTextureDeletion: {
|
||||||
insert(event.startTime() - event.numericData(0), event.numericData(0), event.typeIndex(),
|
insert(event.timestamp() - event.numericData(0), event.numericData(0), event.typeIndex(),
|
||||||
TextureDeletion);
|
TextureDeletion);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case SceneGraphPolishAndSync: {
|
case SceneGraphPolishAndSync: {
|
||||||
qint64 startTime = event.startTime() - event.numericData(0) - event.numericData(1) -
|
qint64 startTime = event.timestamp() - event.numericData(0) - event.numericData(1) -
|
||||||
event.numericData(2) - event.numericData(3);
|
event.numericData(2) - event.numericData(3);
|
||||||
|
|
||||||
startTime += insert(startTime, event.numericData(0), event.typeIndex(), Polish);
|
startTime += insert(startTime, event.numericData(0), event.typeIndex(), Polish);
|
||||||
@@ -207,13 +207,13 @@ void SceneGraphTimelineModel::loadData()
|
|||||||
}
|
}
|
||||||
case SceneGraphWindowsAnimations: {
|
case SceneGraphWindowsAnimations: {
|
||||||
// GUI thread, separate animations stage
|
// GUI thread, separate animations stage
|
||||||
insert(event.startTime() - event.numericData(0), event.numericData(0), event.typeIndex(),
|
insert(event.timestamp() - event.numericData(0), event.numericData(0), event.typeIndex(),
|
||||||
Animations);
|
Animations);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case SceneGraphPolishFrame: {
|
case SceneGraphPolishFrame: {
|
||||||
// GUI thread, separate polish stage
|
// GUI thread, separate polish stage
|
||||||
insert(event.startTime() - event.numericData(0), event.numericData(0), event.typeIndex(),
|
insert(event.timestamp() - event.numericData(0), event.numericData(0), event.typeIndex(),
|
||||||
Polish);
|
Polish);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user