diff options
author | Timothy Arceri <[email protected]> | 2017-06-16 10:17:56 +1000 |
---|---|---|
committer | Timothy Arceri <[email protected]> | 2018-03-20 14:17:33 +1100 |
commit | edded1237607348683f492db313e823dc2e380c3 (patch) | |
tree | 1fb861be1d324eb309fbef50e6b353dfff4a0c83 /src/mesa/main/uniform_query.cpp | |
parent | b13b9eb432a3b67efb29ca25c3e244b467c3c4af (diff) |
mesa: rework ParameterList to allow packing
Currently everything is padded to 4 components. Making the list
more flexible will allow us to do uniform packing.
V2 (suggestions from Nicolai):
- always pass existing calls to _mesa_add_parameter() true for padd_and_align
- fix bindless param value offsets
- remove left over wip logic from pad and align code
- zero out param value padding
- whitespace fix
Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/mesa/main/uniform_query.cpp')
-rw-r--r-- | src/mesa/main/uniform_query.cpp | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/mesa/main/uniform_query.cpp b/src/mesa/main/uniform_query.cpp index a48b6d29218..52b04c92434 100644 --- a/src/mesa/main/uniform_query.cpp +++ b/src/mesa/main/uniform_query.cpp @@ -723,13 +723,15 @@ log_program_parameters(const struct gl_shader_program *shProg) printf("Program %d %s shader parameters:\n", shProg->Name, _mesa_shader_stage_to_string(i)); for (unsigned j = 0; j < prog->Parameters->NumParameters; j++) { - printf("%s: %p %f %f %f %f\n", + unsigned pvo = prog->Parameters->ParameterValueOffset[j]; + printf("%s: %u %p %f %f %f %f\n", prog->Parameters->Parameters[j].Name, - prog->Parameters->ParameterValues[j], - prog->Parameters->ParameterValues[j][0].f, - prog->Parameters->ParameterValues[j][1].f, - prog->Parameters->ParameterValues[j][2].f, - prog->Parameters->ParameterValues[j][3].f); + pvo, + prog->Parameters->ParameterValues + pvo, + prog->Parameters->ParameterValues[pvo].f, + prog->Parameters->ParameterValues[pvo + 1].f, + prog->Parameters->ParameterValues[pvo + 2].f, + prog->Parameters->ParameterValues[pvo + 3].f); } } fflush(stdout); |