blob: ed54965e1030e91612d0799e67030a0b25967a06 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
/*
* Copyright 2018 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#include "GrDebugMarkerOp.h"
#include "GrCaps.h"
#include "GrContext.h"
#include "GrContextPriv.h"
#include "GrGpuCommandBuffer.h"
#include "GrMemoryPool.h"
#include "GrOpFlushState.h"
std::unique_ptr<GrOp> GrDebugMarkerOp::Make(GrContext* context,
GrRenderTargetProxy* proxy,
const SkString& str) {
return std::unique_ptr<GrOp>(new GrDebugMarkerOp(proxy, str));
}
void GrDebugMarkerOp::onExecute(GrOpFlushState* state) {
//SkDebugf("%s\n", fStr.c_str());
if (state->caps().gpuTracingSupport()) {
state->commandBuffer()->insertEventMarker(fStr.c_str());
}
}
|