DescriptionMake GrGLProgram be available to GrGLProgramDataManager
GL APIs such as glProgramPathFragmentInputGenNV need the explicit program id in
order to set the program resources. For GrGLProgramDataManager to call the APIs,
the program id needs to be available to the GrGLProgramDataManager.
One GrGLProgramDataManager is used to explicitly manage the resources of one
GrGLProgram. Refactor the classes to reflect this: make GrGLProgram create and
own GrGLProgramDataManager. This way the program id can be made available through
GrGLProgram backpointer.
In order to do this, remove the population of the program link results
information for uniforms in GrGLProgramDataManager during shader generation.
Instead, accumulate the info to the uniform list of GrGLShaderBuilder. After the
generation, compilation and link is successful, this info can be used to
construct both GrGLProgram and GrGLProgramDataManager.
Changes names of functions to create UniformHandles and convert them to list
indices. This tries to highlight that they're different lists, even though at
the moment they match index-wise. E.g the contract is that handles can be
created based on the shader builder state, and the object can later be set with
the handle and the manager that was created with the builder.
This is needed to support NV_path_rendering for GLES.
Committed: https://skia.googlesource.com/skia/+/dddc18a6bba67ad43a65f4c244b95f76cefef617
Patch Set 1 #Patch Set 2 : #
Total comments: 2
Patch Set 3 : address review comment #Patch Set 4 : fix win warning #
Messages
Total messages: 9 (0 generated)
|