Re: [Mesa-dev] [PATCH 1/2] mesa/marshal: extract ClearBuffer helpers

2017-07-09 Thread Grigori Goronzy
On 2017-07-09 18:52, Matt Turner wrote: +static inline size_t buffer_to_size(GLenum buffer) +{ + switch (buffer) { + case GL_COLOR: + return 4; + case GL_DEPTH_STENCIL: + return 2; + case GL_STENCIL: + case GL_DEPTH: + return 1; + default: + return 0; + } +} + +s

Re: [Mesa-dev] [PATCH 1/2] mesa/marshal: extract ClearBuffer helpers

2017-07-09 Thread Matt Turner
On Sun, Jul 9, 2017 at 9:21 AM, Grigori Goronzy wrote: > Extract clear buffer helper functions in preparation for adding > marshal/unmarshal functions for the various glClearBuffer variants. > --- > src/mesa/main/marshal.c | 74 > +++-- > src/mesa/main

[Mesa-dev] [PATCH 1/2] mesa/marshal: extract ClearBuffer helpers

2017-07-09 Thread Grigori Goronzy
Extract clear buffer helper functions in preparation for adding marshal/unmarshal functions for the various glClearBuffer variants. --- src/mesa/main/marshal.c | 74 +++-- src/mesa/main/marshal.h | 5 ++-- 2 files changed, 50 insertions(+), 29 deletions