Commit b87324f8 by Ben Clayton

Pipeline: Add custom debug printers for SamplerFunction.

SamplerFunction can then be passed to RR_LOG and RR_WATCH. Bug: b/140287657 Change-Id: If37d99469b7df98b539430abdcd184eec81bc08f Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/33471Tested-by: 's avatarBen Clayton <bclayton@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by: 's avatarChris Forbes <chrisforbes@google.com>
parent a683328c
......@@ -115,4 +115,22 @@ namespace sw
};
}
#ifdef ENABLE_RR_PRINT
namespace rr {
template <> struct PrintValue::Ty<sw::SamplerFunction>
{
static std::string fmt(const sw::SamplerFunction& v)
{
return std::string("SamplerFunction[") +
"method: " + std::to_string(v.method) +
", offset: " + std::to_string(v.offset) +
", sample: " + std::to_string(v.sample) +
"]";
}
static std::vector<rr::Value*> val(const sw::SamplerFunction& v) { return {}; }
};
}
#endif // ENABLE_RR_PRINT
#endif // sw_SamplerCore_hpp
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment