Hi, On Tue, 6 Nov 2018 at 13:11, Eric Engestrom <eric.engest...@intel.com> wrote: > On Friday, 2018-11-02 14:40:49 -0700, Eric Anholt wrote: > > +GBM_EXPORT char * > > +gbm_format_get_name(uint32_t gbm_format, struct gbm_format_name_desc *desc) > > +{ > > Actually, This won't work with the two GBM_BO_FORMAT_{X,A}RGB8888; you > should add them as a special case here, something like: > > if (gbm_format == GBM_BO_FORMAT_XRGB8888) > return "XRGB8888"; > > if (gbm_format == GBM_BO_FORMAT_ARGB8888) > return "ARGB8888"; > > followed by your desc->name code.
Perhaps better would be to just lift gbm_format_canonicalize() from src/gbm/backends/dri/gbm_dri.c and use it at function entry. Cheers, Daniel _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev