[Mesa-dev] [PATCH 1/4] gallium: add resource normalization flags (v3)

Keith Whitwell keithw at vmware.com
Tue Aug 17 07:33:55 PDT 2010


On Tue, 2010-08-17 at 00:09 -0700, Luca Barbieri wrote:
> +
> +/* State trackers should support using either normalization in all
> internal drawing
> + * code, using these flag to tell which one to use.
> + *
> + * If they do not have such support, then they should indicate the
> + * normalization needed using the bind flags, but they should be
> aware
> + * that if it is different than the API-needed one, some drivers may
> + * fail creation because they only support one normalization at once.
> + *
> + * State trackers must not set these flags.
> + *
> + * Drivers should set these flags to inform the state tracker of the
> normalization
> + * it should use in internal drawing code, if they prefer any.
> + *
> + * Drivers who need to always have the same normalization used for a
> given
> + * resource must set these flags according to the bind flags above,
> and refuse
> + * creation if too many normalization bind flags are set.
> + */
> +#define PIPE_RESOURCE_FLAG_PREFER_UNNORMALIZED_COORDS (1 << 1)
> +#define PIPE_RESOURCE_FLAG_PREFER_NORMALIZED_COORDS (1 << 2)
> + 

Again, I don't see why this needs to be per-resource information --
surely the hardware has a single preference that it keeps under all
circumstances?

Or even if it's more complex than that, it's hard to believe it is so
random it needs to be handled per-resource.

Keith



More information about the mesa-dev mailing list