jdk/src/share/native/sun/java2d/loops/FourByteAbgrPre.h
author duke
Sat, 01 Dec 2007 00:00:00 +0000
changeset 2 90ce3da70b43
child 549 4273b1234967
permissions -rw-r--r--
Initial load
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     1
/*
90ce3da70b43 Initial load
duke
parents:
diff changeset
     2
 * Copyright 2000-2004 Sun Microsystems, Inc.  All Rights Reserved.
90ce3da70b43 Initial load
duke
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
90ce3da70b43 Initial load
duke
parents:
diff changeset
     4
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
90ce3da70b43 Initial load
duke
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
90ce3da70b43 Initial load
duke
parents:
diff changeset
     7
 * published by the Free Software Foundation.  Sun designates this
90ce3da70b43 Initial load
duke
parents:
diff changeset
     8
 * particular file as subject to the "Classpath" exception as provided
90ce3da70b43 Initial load
duke
parents:
diff changeset
     9
 * by Sun in the LICENSE file that accompanied this code.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    10
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    11
 * This code is distributed in the hope that it will be useful, but WITHOUT
90ce3da70b43 Initial load
duke
parents:
diff changeset
    12
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
90ce3da70b43 Initial load
duke
parents:
diff changeset
    13
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
90ce3da70b43 Initial load
duke
parents:
diff changeset
    14
 * version 2 for more details (a copy is included in the LICENSE file that
90ce3da70b43 Initial load
duke
parents:
diff changeset
    15
 * accompanied this code).
90ce3da70b43 Initial load
duke
parents:
diff changeset
    16
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    17
 * You should have received a copy of the GNU General Public License version
90ce3da70b43 Initial load
duke
parents:
diff changeset
    18
 * 2 along with this work; if not, write to the Free Software Foundation,
90ce3da70b43 Initial load
duke
parents:
diff changeset
    19
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    20
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    21
 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
90ce3da70b43 Initial load
duke
parents:
diff changeset
    22
 * CA 95054 USA or visit www.sun.com if you need additional information or
90ce3da70b43 Initial load
duke
parents:
diff changeset
    23
 * have any questions.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    24
 */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    25
90ce3da70b43 Initial load
duke
parents:
diff changeset
    26
#ifndef FourByteAbgrPre_h_Included
90ce3da70b43 Initial load
duke
parents:
diff changeset
    27
#define FourByteAbgrPre_h_Included
90ce3da70b43 Initial load
duke
parents:
diff changeset
    28
90ce3da70b43 Initial load
duke
parents:
diff changeset
    29
/*
90ce3da70b43 Initial load
duke
parents:
diff changeset
    30
 * This file contains macro and type definitions used by the macros in
90ce3da70b43 Initial load
duke
parents:
diff changeset
    31
 * LoopMacros.h to manipulate a surface of type "FourByteAbgrPre".
90ce3da70b43 Initial load
duke
parents:
diff changeset
    32
 */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    33
90ce3da70b43 Initial load
duke
parents:
diff changeset
    34
typedef jint    FourByteAbgrPrePixelType;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    35
typedef jubyte  FourByteAbgrPreDataType;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    36
90ce3da70b43 Initial load
duke
parents:
diff changeset
    37
#define FourByteAbgrPrePixelStride              4
90ce3da70b43 Initial load
duke
parents:
diff changeset
    38
90ce3da70b43 Initial load
duke
parents:
diff changeset
    39
#define DeclareFourByteAbgrPreLoadVars(PREFIX)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    40
#define DeclareFourByteAbgrPreStoreVars(PREFIX)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    41
#define SetFourByteAbgrPreStoreVarsYPos(PREFIX, pRasInfo, y)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    42
#define SetFourByteAbgrPreStoreVarsXPos(PREFIX, pRasInfo, x)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    43
#define InitFourByteAbgrPreLoadVars(PREFIX, pRasInfo)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    44
#define InitFourByteAbgrPreStoreVarsY(PREFIX, pRasInfo)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    45
#define InitFourByteAbgrPreStoreVarsX(PREFIX, pRasInfo)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    46
#define NextFourByteAbgrPreStoreVarsX(PREFIX)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    47
#define NextFourByteAbgrPreStoreVarsY(PREFIX)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    48
90ce3da70b43 Initial load
duke
parents:
diff changeset
    49
90ce3da70b43 Initial load
duke
parents:
diff changeset
    50
#define FourByteAbgrPrePixelFromArgb(pixel, rgb, pRasInfo) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    51
    do { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    52
        jint a, r, g, b; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    53
        if (((rgb) >> 24) == -1) { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    54
            (pixel) = (((rgb) << 8) | (((juint) (rgb)) >> 24)); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    55
        } else { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    56
            ExtractIntDcmComponents1234(rgb, a, r, g, b); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    57
            r = MUL8(a, r); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    58
            g = MUL8(a, g); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    59
            b = MUL8(a, b); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    60
            (pixel) = ComposeIntDcmComponents1234(r, g, b, a); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    61
        } \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    62
    } while (0)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    63
90ce3da70b43 Initial load
duke
parents:
diff changeset
    64
#define StoreFourByteAbgrPrePixel(pRas, x, pixel) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    65
    do { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    66
        (pRas)[4*(x)+0] = (jubyte) ((pixel) >> 0); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    67
        (pRas)[4*(x)+1] = (jubyte) ((pixel) >> 8); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    68
        (pRas)[4*(x)+2] = (jubyte) ((pixel) >> 16); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    69
        (pRas)[4*(x)+3] = (jubyte) ((pixel) >> 24); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    70
    } while (0)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    71
90ce3da70b43 Initial load
duke
parents:
diff changeset
    72
#define DeclareFourByteAbgrPrePixelData(PREFIX) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    73
    jubyte PREFIX ## 0, PREFIX ## 1, PREFIX ## 2, PREFIX ## 3;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    74
90ce3da70b43 Initial load
duke
parents:
diff changeset
    75
#define ExtractFourByteAbgrPrePixelData(PIXEL, PREFIX) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    76
    do { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    77
        PREFIX ## 0 = (jubyte) (PIXEL >> 0); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    78
        PREFIX ## 1 = (jubyte) (PIXEL >> 8); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    79
        PREFIX ## 2 = (jubyte) (PIXEL >> 16); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    80
        PREFIX ## 3 = (jubyte) (PIXEL >> 24); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    81
    } while (0)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    82
90ce3da70b43 Initial load
duke
parents:
diff changeset
    83
#define StoreFourByteAbgrPrePixelData(pPix, x, pixel, PREFIX) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    84
    do { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    85
        pPix[4*(x)+0] = PREFIX ## 0; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    86
        pPix[4*(x)+1] = PREFIX ## 1; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    87
        pPix[4*(x)+2] = PREFIX ## 2; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    88
        pPix[4*(x)+3] = PREFIX ## 3; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    89
    } while (0)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    90
90ce3da70b43 Initial load
duke
parents:
diff changeset
    91
90ce3da70b43 Initial load
duke
parents:
diff changeset
    92
#define LoadFourByteAbgrPreTo1IntRgb(pRas, PREFIX, x, rgb) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    93
    LoadFourByteAbgrPreTo1IntArgb(pRas, PREFIX, x, rgb)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    94
90ce3da70b43 Initial load
duke
parents:
diff changeset
    95
#define LoadFourByteAbgrPreTo1IntArgb(pRas, PREFIX, x, argb) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    96
    do { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    97
        jint a = (pRas)[4*(x)+0]; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    98
        if ((a == 0xff) || (a == 0)) { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
    99
            (argb) = (((pRas)[4*(x)+1] << 0) | \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   100
                      ((pRas)[4*(x)+2] << 8) | \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   101
                      ((pRas)[4*(x)+3] << 16) | \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   102
                      (a << 24)); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   103
        } else { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   104
            jint r, g, b; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   105
            b = DIV8((pRas)[4*(x)+1], a); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   106
            g = DIV8((pRas)[4*(x)+2], a); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   107
            r = DIV8((pRas)[4*(x)+3], a); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   108
            (argb) = ComposeIntDcmComponents1234(a, r, g, b); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   109
        } \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   110
    } while (0)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   111
90ce3da70b43 Initial load
duke
parents:
diff changeset
   112
#define LoadFourByteAbgrPreTo3ByteRgb(pRas, PREFIX, x, r, g, b) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   113
    do { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   114
        jint a; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   115
        LoadFourByteAbgrPreTo4ByteArgb(pRas, PREFIX, x, a, r, g, b); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   116
    } while (0)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   117
90ce3da70b43 Initial load
duke
parents:
diff changeset
   118
#define LoadFourByteAbgrPreTo4ByteArgb(pRas, PREFIX, x, a, r, g, b) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   119
    do { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   120
        (a) = (pRas)[4*(x)+0]; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   121
        (b) = (pRas)[4*(x)+1]; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   122
        (g) = (pRas)[4*(x)+2]; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   123
        (r) = (pRas)[4*(x)+3]; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   124
        if ((a != 0xff) && (a != 0)) { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   125
            r = DIV8(r, a); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   126
            g = DIV8(g, a); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   127
            b = DIV8(b, a); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   128
        } \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   129
    } while (0)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   130
90ce3da70b43 Initial load
duke
parents:
diff changeset
   131
#define StoreFourByteAbgrPreFrom1IntRgb(pRas, PREFIX, x, rgb) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   132
    do { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   133
        (pRas)[4*(x)+0] = (jubyte) 0xff; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   134
        (pRas)[4*(x)+1] = (jubyte) ((rgb) >> 0); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   135
        (pRas)[4*(x)+2] = (jubyte) ((rgb) >> 8); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   136
        (pRas)[4*(x)+3] = (jubyte) ((rgb) >> 16); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   137
    } while (0)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   138
90ce3da70b43 Initial load
duke
parents:
diff changeset
   139
#define StoreFourByteAbgrPreFrom1IntArgb(pRas, PREFIX, x, argb) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   140
    do { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   141
        if ((((argb) >> 24) + 1) == 0) { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   142
            (pRas)[4*(x)+0] = (jubyte) ((argb) >> 24); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   143
            (pRas)[4*(x)+1] = (jubyte) ((argb) >> 0); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   144
            (pRas)[4*(x)+2] = (jubyte) ((argb) >> 8); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   145
            (pRas)[4*(x)+3] = (jubyte) ((argb) >> 16); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   146
        } else { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   147
            jint a, r, g, b; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   148
            ExtractIntDcmComponents1234(argb, a, r, g, b); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   149
            (pRas)[4*(x)+0] = (jubyte) a; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   150
            (pRas)[4*(x)+1] = MUL8(a, b); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   151
            (pRas)[4*(x)+2] = MUL8(a, g); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   152
            (pRas)[4*(x)+3] = MUL8(a, r); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   153
        } \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   154
    } while (0)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   155
90ce3da70b43 Initial load
duke
parents:
diff changeset
   156
#define StoreFourByteAbgrPreFrom3ByteRgb(pRas, PREFIX, x, r, g, b) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   157
    do { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   158
        (pRas)[4*(x)+0] = (jubyte) 0xff; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   159
        (pRas)[4*(x)+1] = (jubyte) (b); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   160
        (pRas)[4*(x)+2] = (jubyte) (g); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   161
        (pRas)[4*(x)+3] = (jubyte) (r); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   162
    } while (0)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   163
90ce3da70b43 Initial load
duke
parents:
diff changeset
   164
#define StoreFourByteAbgrPreFrom4ByteArgb(pRas, PREFIX, x, a, r, g, b) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   165
    do { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   166
        if ((a) == 0xff) { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   167
            StoreFourByteAbgrPreFrom3ByteRgb(pRas, PREFIX, x, r, g, b); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   168
        } else { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   169
            (pRas)[4*(x)+0] = (jubyte) (a); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   170
            (pRas)[4*(x)+1] = MUL8(a, b); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   171
            (pRas)[4*(x)+2] = MUL8(a, g); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   172
            (pRas)[4*(x)+3] = MUL8(a, r); \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   173
        } \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   174
    } while (0)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   175
90ce3da70b43 Initial load
duke
parents:
diff changeset
   176
#define CopyFourByteAbgrPreToIntArgbPre(pRGB, i, PREFIX, pRow, x) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   177
    (pRGB)[i] = (((pRow)[4*(x)+0] << 24) | \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   178
                 ((pRow)[4*(x)+1] << 0) | \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   179
                 ((pRow)[4*(x)+2] << 8) | \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   180
                 ((pRow)[4*(x)+3] << 16))
90ce3da70b43 Initial load
duke
parents:
diff changeset
   181
90ce3da70b43 Initial load
duke
parents:
diff changeset
   182
90ce3da70b43 Initial load
duke
parents:
diff changeset
   183
#define DeclareFourByteAbgrPreAlphaLoadData(PREFIX)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   184
#define InitFourByteAbgrPreAlphaLoadData(PREFIX, pRasInfo)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   185
90ce3da70b43 Initial load
duke
parents:
diff changeset
   186
#define LoadAlphaFromFourByteAbgrPreFor4ByteArgb(pRas, PREFIX, COMP_PREFIX) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   187
    COMP_PREFIX ## A = (pRas)[0]
90ce3da70b43 Initial load
duke
parents:
diff changeset
   188
90ce3da70b43 Initial load
duke
parents:
diff changeset
   189
#define Postload4ByteArgbFromFourByteAbgrPre(pRas, PREFIX, COMP_PREFIX) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   190
    do { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   191
        COMP_PREFIX ## B = (pRas)[1]; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   192
        COMP_PREFIX ## G = (pRas)[2]; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   193
        COMP_PREFIX ## R = (pRas)[3]; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   194
    } while (0)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   195
90ce3da70b43 Initial load
duke
parents:
diff changeset
   196
90ce3da70b43 Initial load
duke
parents:
diff changeset
   197
#define FourByteAbgrPreIsPremultiplied  1
90ce3da70b43 Initial load
duke
parents:
diff changeset
   198
90ce3da70b43 Initial load
duke
parents:
diff changeset
   199
#define DeclareFourByteAbgrPreBlendFillVars(PREFIX)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   200
90ce3da70b43 Initial load
duke
parents:
diff changeset
   201
#define ClearFourByteAbgrPreBlendFillVars(PREFIX, argb)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   202
90ce3da70b43 Initial load
duke
parents:
diff changeset
   203
#define InitFourByteAbgrPreBlendFillVarsNonPre(PREFIX, argb, COMP_PREFIX)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   204
90ce3da70b43 Initial load
duke
parents:
diff changeset
   205
#define InitFourByteAbgrPreBlendFillVarsPre(PREFIX, argb, COMP_PREFIX)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   206
90ce3da70b43 Initial load
duke
parents:
diff changeset
   207
#define StoreFourByteAbgrPreBlendFill(pRas, PREFIX, x, argb, COMP_PREFIX) \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   208
    StoreFourByteAbgrPreFrom4ByteArgbComps(pRas, PREFIX, x, COMP_PREFIX)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   209
90ce3da70b43 Initial load
duke
parents:
diff changeset
   210
#define StoreFourByteAbgrPreFrom4ByteArgbComps(pRas, PREFIX, x, COMP_PREFIX)\
90ce3da70b43 Initial load
duke
parents:
diff changeset
   211
    do { \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   212
        (pRas)[4*(x)+0] = (jubyte) COMP_PREFIX ## A; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   213
        (pRas)[4*(x)+1] = (jubyte) COMP_PREFIX ## B; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   214
        (pRas)[4*(x)+2] = (jubyte) COMP_PREFIX ## G; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   215
        (pRas)[4*(x)+3] = (jubyte) COMP_PREFIX ## R; \
90ce3da70b43 Initial load
duke
parents:
diff changeset
   216
    } while (0)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   217
90ce3da70b43 Initial load
duke
parents:
diff changeset
   218
#endif /* FourByteAbgrPre_h_Included */