Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[xsrc/trunk]: xsrc/external/mit/MesaLib/src Add more generated files from mes...



details:   https://anonhg.NetBSD.org/xsrc/rev/4bed635ed58c
branches:  trunk
changeset: 10404:4bed635ed58c
user:      maya <maya%NetBSD.org@localhost>
date:      Tue Sep 24 21:40:36 2019 +0000

description:
Add more generated files from mesa 19.1.7.

Generated by doing a regular build using pkgsrc.

diffstat:

 external/mit/MesaLib/src/gallium/auxiliary/u_format_table.c    |  52569 ++++++++++
 external/mit/MesaLib/src/gallium/auxiliary/u_indices_gen.c     |  17638 +++
 external/mit/MesaLib/src/gallium/auxiliary/u_unfilled_gen.c    |   1416 +
 external/mit/MesaLib/src/gallium/drivers/radeonsi/si_driinfo.h |     64 +
 external/mit/MesaLib/src/mapi/glapi/api_exec.c                 |   1697 +
 external/mit/MesaLib/src/mapi/glapi/enums.c                    |   7450 +
 external/mit/MesaLib/src/mapi/glapi/glapi_mapi_tmp.h           |  14283 ++
 external/mit/MesaLib/src/mapi/glapi/indirect.c                 |   9003 +
 external/mit/MesaLib/src/mapi/glapi/indirect.h                 |    724 +
 external/mit/MesaLib/src/mapi/glapi/indirect_init.c            |   1215 +
 external/mit/MesaLib/src/mapi/glapi/indirect_size.c            |    367 +
 external/mit/MesaLib/src/mapi/glapi/indirect_size.h            |     83 +
 external/mit/MesaLib/src/mapi/glapi/marshal_generated.c        |  45605 ++++++++
 external/mit/MesaLib/src/mesa/format_info.h                    |   3884 +
 external/mit/MesaLib/src/mesa/get_hash.h                       |   2219 +
 external/mit/MesaLib/src/mesa/main/dispatch.h                  |  18133 +++
 external/mit/MesaLib/src/mesa/main/format_fallback.c           |    352 +
 external/mit/MesaLib/src/mesa/main/format_pack.c               |  11288 ++
 external/mit/MesaLib/src/mesa/main/format_unpack.c             |   7654 +
 external/mit/MesaLib/src/mesa/main/marshal_generated.h         |    943 +
 external/mit/MesaLib/src/mesa/main/remap_helper.h              |   8350 +
 external/mit/MesaLib/src/mesa/matypes.h                        |    157 +
 external/mit/MesaLib/src/mesa/program/program_parse.tab.c      |   5171 +
 external/mit/MesaLib/src/mesa/program/program_parse.tab.h      |    215 +
 external/mit/MesaLib/src/util/format_srgb.c                    |    178 +
 external/mit/MesaLib/src/util/xmlpool/options.h                |    367 +
 26 files changed, 211025 insertions(+), 0 deletions(-)

diffs (truncated from 211129 to 300 lines):

diff -r db5e4de20556 -r 4bed635ed58c external/mit/MesaLib/src/gallium/auxiliary/u_format_table.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/external/mit/MesaLib/src/gallium/auxiliary/u_format_table.c       Tue Sep 24 21:40:36 2019 +0000
@@ -0,0 +1,52569 @@
+/* This file is autogenerated by u_format_table.py from u_format.csv. Do not edit directly. */
+
+/**************************************************************************
+ *
+ * Copyright 2010 VMware, Inc.
+ * All Rights Reserved.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sub license, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ *
+ * The above copyright notice and this permission notice (including the
+ * next paragraph) shall be included in all copies or substantial portions
+ * of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
+ * IN NO EVENT SHALL VMWARE AND/OR ITS SUPPLIERS BE LIABLE FOR
+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ *
+ **************************************************************************/
+
+#include "u_format.h"
+#include "u_format_bptc.h"
+#include "u_format_s3tc.h"
+#include "u_format_rgtc.h"
+#include "u_format_latc.h"
+#include "u_format_etc.h"
+
+
+#include "pipe/p_compiler.h"
+#include "util/u_math.h"
+#include "u_half.h"
+#include "u_format.h"
+#include "u_format_other.h"
+#include "util/format_srgb.h"
+#include "u_format_yuv.h"
+#include "u_format_zs.h"
+
+union util_format_none {
+   uint8_t value;
+   struct {
+      uint8_t r;
+   } chan;
+};
+
+static inline void
+util_format_none_unpack_rgba_float(float *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height)
+{
+   unsigned x, y;
+   for(y = 0; y < height; y += 1) {
+      float *dst = dst_row;
+      const uint8_t *src = src_row;
+      for(x = 0; x < width; x += 1) {
+         uint8_t value = *(const uint8_t *)src;
+         uint8_t r;
+         r = value;
+         dst[0] = (float)r; /* r */
+         dst[1] = 0; /* g */
+         dst[2] = 0; /* b */
+         dst[3] = 1; /* a */
+         src += 1;
+         dst += 4;
+      }
+      src_row += src_stride;
+      dst_row += dst_stride/sizeof(*dst_row);
+   }
+}
+
+static inline void
+util_format_none_pack_rgba_float(uint8_t *dst_row, unsigned dst_stride, const float *src_row, unsigned src_stride, unsigned width, unsigned height)
+{
+   unsigned x, y;
+   for(y = 0; y < height; y += 1) {
+      const float *src = src_row;
+      uint8_t *dst = dst_row;
+      for(x = 0; x < width; x += 1) {
+         uint8_t value = 0;
+         value |= (uint8_t)CLAMP(src[0], 0.0f, 255.0f);
+         *(uint8_t *)dst = value;
+         src += 4;
+         dst += 1;
+      }
+      dst_row += dst_stride;
+      src_row += src_stride/sizeof(*src_row);
+   }
+}
+
+static inline void
+util_format_none_fetch_rgba_float(float *dst, const uint8_t *src, UNUSED unsigned i, UNUSED unsigned j)
+{
+         uint8_t value = *(const uint8_t *)src;
+         uint8_t r;
+         r = value;
+         dst[0] = (float)r; /* r */
+         dst[1] = 0; /* g */
+         dst[2] = 0; /* b */
+         dst[3] = 1; /* a */
+}
+
+static inline void
+util_format_none_unpack_rgba_8unorm(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height)
+{
+   unsigned x, y;
+   for(y = 0; y < height; y += 1) {
+      uint8_t *dst = dst_row;
+      const uint8_t *src = src_row;
+      for(x = 0; x < width; x += 1) {
+         uint8_t value = *(const uint8_t *)src;
+         uint8_t r;
+         r = value;
+         dst[0] = (uint8_t)(((uint32_t)MIN2(r, 1)) * 0xff / 0x1); /* r */
+         dst[1] = 0; /* g */
+         dst[2] = 0; /* b */
+         dst[3] = 255; /* a */
+         src += 1;
+         dst += 4;
+      }
+      src_row += src_stride;
+      dst_row += dst_stride/sizeof(*dst_row);
+   }
+}
+
+static inline void
+util_format_none_pack_rgba_8unorm(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height)
+{
+   unsigned x, y;
+   for(y = 0; y < height; y += 1) {
+      const uint8_t *src = src_row;
+      uint8_t *dst = dst_row;
+      for(x = 0; x < width; x += 1) {
+         uint8_t value = 0;
+         value |= (uint8_t)(((uint32_t)src[0]) * 0x1 / 0xff);
+         *(uint8_t *)dst = value;
+         src += 4;
+         dst += 1;
+      }
+      dst_row += dst_stride;
+      src_row += src_stride/sizeof(*src_row);
+   }
+}
+
+union util_format_b8g8r8a8_unorm {
+   uint32_t value;
+   struct {
+#ifdef PIPE_ARCH_BIG_ENDIAN
+      uint8_t b;
+      uint8_t g;
+      uint8_t r;
+      uint8_t a;
+#else
+      uint8_t b;
+      uint8_t g;
+      uint8_t r;
+      uint8_t a;
+#endif
+   } chan;
+};
+
+static inline void
+util_format_b8g8r8a8_unorm_unpack_rgba_float(float *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height)
+{
+   unsigned x, y;
+   for(y = 0; y < height; y += 1) {
+      float *dst = dst_row;
+      const uint8_t *src = src_row;
+      for(x = 0; x < width; x += 1) {
+#ifdef PIPE_ARCH_BIG_ENDIAN
+         uint32_t value = *(const uint32_t *)src;
+         uint32_t b;
+         uint32_t g;
+         uint32_t r;
+         uint32_t a;
+         b = value >> 24;
+         g = (value >> 16) & 0xff;
+         r = (value >> 8) & 0xff;
+         a = (value) & 0xff;
+         dst[0] = ubyte_to_float(r); /* r */
+         dst[1] = ubyte_to_float(g); /* g */
+         dst[2] = ubyte_to_float(b); /* b */
+         dst[3] = ubyte_to_float(a); /* a */
+#else
+         uint32_t value = *(const uint32_t *)src;
+         uint32_t b;
+         uint32_t g;
+         uint32_t r;
+         uint32_t a;
+         b = (value) & 0xff;
+         g = (value >> 8) & 0xff;
+         r = (value >> 16) & 0xff;
+         a = value >> 24;
+         dst[0] = ubyte_to_float(r); /* r */
+         dst[1] = ubyte_to_float(g); /* g */
+         dst[2] = ubyte_to_float(b); /* b */
+         dst[3] = ubyte_to_float(a); /* a */
+#endif
+         src += 4;
+         dst += 4;
+      }
+      src_row += src_stride;
+      dst_row += dst_stride/sizeof(*dst_row);
+   }
+}
+
+static inline void
+util_format_b8g8r8a8_unorm_pack_rgba_float(uint8_t *dst_row, unsigned dst_stride, const float *src_row, unsigned src_stride, unsigned width, unsigned height)
+{
+   unsigned x, y;
+   for(y = 0; y < height; y += 1) {
+      const float *src = src_row;
+      uint8_t *dst = dst_row;
+      for(x = 0; x < width; x += 1) {
+#ifdef PIPE_ARCH_BIG_ENDIAN
+         uint32_t value = 0;
+         value |= (float_to_ubyte(src[2])) << 24;
+         value |= ((float_to_ubyte(src[1])) & 0xff) << 16;
+         value |= ((float_to_ubyte(src[0])) & 0xff) << 8;
+         value |= (float_to_ubyte(src[3])) & 0xff;
+         *(uint32_t *)dst = value;
+#else
+         uint32_t value = 0;
+         value |= (float_to_ubyte(src[2])) & 0xff;
+         value |= ((float_to_ubyte(src[1])) & 0xff) << 8;
+         value |= ((float_to_ubyte(src[0])) & 0xff) << 16;
+         value |= (float_to_ubyte(src[3])) << 24;
+         *(uint32_t *)dst = value;
+#endif
+         src += 4;
+         dst += 4;
+      }
+      dst_row += dst_stride;
+      src_row += src_stride/sizeof(*src_row);
+   }
+}
+
+static inline void
+util_format_b8g8r8a8_unorm_fetch_rgba_float(float *dst, const uint8_t *src, UNUSED unsigned i, UNUSED unsigned j)
+{
+#ifdef PIPE_ARCH_BIG_ENDIAN
+         uint32_t value = *(const uint32_t *)src;
+         uint32_t b;
+         uint32_t g;
+         uint32_t r;
+         uint32_t a;
+         b = value >> 24;
+         g = (value >> 16) & 0xff;
+         r = (value >> 8) & 0xff;
+         a = (value) & 0xff;
+         dst[0] = ubyte_to_float(r); /* r */
+         dst[1] = ubyte_to_float(g); /* g */
+         dst[2] = ubyte_to_float(b); /* b */
+         dst[3] = ubyte_to_float(a); /* a */
+#else
+         uint32_t value = *(const uint32_t *)src;
+         uint32_t b;
+         uint32_t g;
+         uint32_t r;
+         uint32_t a;
+         b = (value) & 0xff;
+         g = (value >> 8) & 0xff;
+         r = (value >> 16) & 0xff;
+         a = value >> 24;
+         dst[0] = ubyte_to_float(r); /* r */
+         dst[1] = ubyte_to_float(g); /* g */
+         dst[2] = ubyte_to_float(b); /* b */
+         dst[3] = ubyte_to_float(a); /* a */
+#endif
+}
+
+static inline void
+util_format_b8g8r8a8_unorm_unpack_rgba_8unorm(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height)
+{
+   unsigned x, y;
+   for(y = 0; y < height; y += 1) {
+      uint8_t *dst = dst_row;
+      const uint8_t *src = src_row;
+      for(x = 0; x < width; x += 1) {
+#ifdef PIPE_ARCH_BIG_ENDIAN
+         uint32_t value = *(const uint32_t *)src;
+         uint32_t b;
+         uint32_t g;
+         uint32_t r;
+         uint32_t a;
+         b = value >> 24;
+         g = (value >> 16) & 0xff;
+         r = (value >> 8) & 0xff;
+         a = (value) & 0xff;
+         dst[0] = r; /* r */
+         dst[1] = g; /* g */



Home | Main Index | Thread Index | Old Index