summaryrefslogtreecommitdiff
path: root/retrace
diff options
context:
space:
mode:
authorMark Janes <mark.a.janes@intel.com>2017-05-30 16:05:22 -0700
committerMark Janes <mark.a.janes@intel.com>2017-06-19 14:10:08 -0700
commitea2d25888abf44c6e9c28811ab11c14a59c0f24f (patch)
treea4fb166052d7c7a088e59a226321688ebd8d69ff /retrace
parent35c96a1cf83129ca81104c3bb26b5f29bf2bace3 (diff)
StateTrack: track glBindProgramPipeline
Diffstat (limited to 'retrace')
-rw-r--r--retrace/daemon/glframe_state.cpp11
-rw-r--r--retrace/daemon/glframe_state.hpp3
2 files changed, 13 insertions, 1 deletions
diff --git a/retrace/daemon/glframe_state.cpp b/retrace/daemon/glframe_state.cpp
index 3df2c6f1..0a057a97 100644
--- a/retrace/daemon/glframe_state.cpp
+++ b/retrace/daemon/glframe_state.cpp
@@ -77,6 +77,7 @@ StateTrack::TrackMap::TrackMap() {
lookup["glGetUniformBlockIndex"] = &StateTrack::trackGetUniformBlockIndex;
lookup["glUniformBlockBinding"] = &StateTrack::trackUniformBlockBinding;
lookup["glBindFragDataLocation"] = &StateTrack::trackBindFragDataLocation;
+ lookup["glBindProgramPipeline"] = &StateTrack::trackBindProgramPipeline;
}
bool
@@ -758,6 +759,16 @@ StateTrack::trackBindFragDataLocation(const trace::Call &call) {
}
void
+StateTrack::trackBindProgramPipeline(const trace::Call &call) {
+ int call_pipeline = call.args[0].value->toDouble();
+ if (!call_pipeline)
+ current_pipeline = 0;
+ else
+ current_pipeline = getRetracedPipeline(call_pipeline);
+}
+
+
+void
StateTrack::onAssembly(ShaderType st, AssemblyType at,
const std::string &assembly) {
if (!current_program)
diff --git a/retrace/daemon/glframe_state.hpp b/retrace/daemon/glframe_state.hpp
index 3684462a..2b2fe5b2 100644
--- a/retrace/daemon/glframe_state.hpp
+++ b/retrace/daemon/glframe_state.hpp
@@ -148,9 +148,10 @@ class StateTrack {
void trackGetUniformBlockIndex(const trace::Call &);
void trackUniformBlockBinding(const trace::Call &);
void trackBindFragDataLocation(const trace::Call &);
+ void trackBindProgramPipeline(const trace::Call &);
OutputPoller *m_poller;
- int current_program;
+ int current_program, current_pipeline;
std::map<int, std::string> shader_to_source;
std::map<int, int> shader_to_type;
std::map<std::string, int> source_to_shader;