Skip to content

Commit 98916cd

Browse files
corporatesharkmeta-codesync[bot]
authored andcommitted
igl | Add Tracy profiler markers to FramebufferWrapper
Reviewed By: rudybear Differential Revision: D115179574 fbshipit-source-id: e4f2522351054666408bfc2fb0ca8b0d30dd06a8
1 parent 0ee051c commit 98916cd

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

src/igl/FramebufferWrapper.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,23 @@
77

88
#include <igl/FramebufferWrapper.h>
99

10+
#include <igl/Macros.h>
11+
1012
namespace igl {
1113

1214
FramebufferWrapper::FramebufferWrapper(std::shared_ptr<IFramebuffer> framebuffer) :
1315
framebuffer_(std::move(framebuffer)) {}
1416

1517
base::IAttachmentInterop* IGL_NULLABLE FramebufferWrapper::getColorAttachment(size_t index) const {
18+
IGL_PROFILER_FUNCTION();
1619
if (!framebuffer_) {
1720
return nullptr;
1821
}
1922
return framebuffer_->getColorAttachment(index).get();
2023
}
2124

2225
base::IAttachmentInterop* IGL_NULLABLE FramebufferWrapper::getDepthAttachment() const {
26+
IGL_PROFILER_FUNCTION();
2327
if (!framebuffer_) {
2428
return nullptr;
2529
}
@@ -33,13 +37,15 @@ void* IGL_NULLABLE FramebufferWrapper::getNativeFramebuffer() const {
3337

3438
std::shared_ptr<ITexture> FramebufferWrapper::getColorAttachmentTexture(
3539
size_t index) const noexcept {
40+
IGL_PROFILER_FUNCTION();
3641
if (!framebuffer_) {
3742
return nullptr;
3843
}
3944
return framebuffer_->getColorAttachment(index);
4045
}
4146

4247
std::shared_ptr<ITexture> FramebufferWrapper::getDepthAttachmentTexture() const noexcept {
48+
IGL_PROFILER_FUNCTION();
4349
if (!framebuffer_) {
4450
return nullptr;
4551
}

0 commit comments

Comments
 (0)