aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/compute/hs/gen/transpose.h
blob: 83f6fc4e4291edc55c816a4317fb96d781fa9d55 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
/*
 * Copyright 2018 Google Inc.
 *
 * Use of this source code is governed by a BSD-style license that can
 * be found in the LICENSE file.
 *
 */

#pragma once

//
//
//

#include <stdint.h>

//
// There must be an even number of rows.  This is enforced elsewhere.
//
// The transpose requires (cols_log2 * rows/2) row-pair blends.
//

void
hsg_transpose(uint32_t                   const cols_log2,
              uint32_t                   const rows,
              void *                           blend,
              void *                           remap,
              void (*pfn_blend)(uint32_t const cols_log2,
                                uint32_t const row_ll, // lower-left
                                uint32_t const row_ur, // upper-right
                                void *         blend),
              void (*pfn_remap)(uint32_t const row_from,
                                uint32_t const row_to,
                                void *         remap));

//
//
//