ReactOS Fundraising Campaign 2012
 
€ 4,410 / € 30,000

Information | Donate

Home | Info | Community | Development | myReactOS | Contact Us

  1. Home
  2. Community
  3. Development
  4. myReactOS
  5. Fundraiser 2012

  1. Main Page
  2. Alphabetical List
  3. Data Structures
  4. Directories
  5. File List
  6. Data Fields
  7. Globals
  8. Related Pages

ReactOS Development > Doxygen

common_x86_macros.h
Go to the documentation of this file.
00001 
00002 /*
00003  * Mesa 3-D graphics library
00004  * Version:  3.5
00005  *
00006  * Copyright (C) 1999-2001  Brian Paul   All Rights Reserved.
00007  *
00008  * Permission is hereby granted, free of charge, to any person obtaining a
00009  * copy of this software and associated documentation files (the "Software"),
00010  * to deal in the Software without restriction, including without limitation
00011  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
00012  * and/or sell copies of the Software, and to permit persons to whom the
00013  * Software is furnished to do so, subject to the following conditions:
00014  *
00015  * The above copyright notice and this permission notice shall be included
00016  * in all copies or substantial portions of the Software.
00017  *
00018  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
00019  * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
00020  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
00021  * BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
00022  * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
00023  * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
00024  *
00025  * Authors:
00026  *    Gareth Hughes
00027  */
00028 
00029 #ifndef __COMMON_X86_MACROS_H__
00030 #define __COMMON_X86_MACROS_H__
00031 
00032 
00033 /* =============================================================
00034  * Transformation function declarations:
00035  */
00036 
00037 #define XFORM_ARGS  GLvector4f *to_vec,             \
00038             const GLfloat m[16],                \
00039             const GLvector4f *from_vec
00040 
00041 #define DECLARE_XFORM_GROUP( pfx, sz ) \
00042 extern void _ASMAPI _mesa_##pfx##_transform_points##sz##_general( XFORM_ARGS );     \
00043 extern void _ASMAPI _mesa_##pfx##_transform_points##sz##_identity( XFORM_ARGS );    \
00044 extern void _ASMAPI _mesa_##pfx##_transform_points##sz##_3d_no_rot( XFORM_ARGS );   \
00045 extern void _ASMAPI _mesa_##pfx##_transform_points##sz##_perspective( XFORM_ARGS ); \
00046 extern void _ASMAPI _mesa_##pfx##_transform_points##sz##_2d( XFORM_ARGS );      \
00047 extern void _ASMAPI _mesa_##pfx##_transform_points##sz##_2d_no_rot( XFORM_ARGS );   \
00048 extern void _ASMAPI _mesa_##pfx##_transform_points##sz##_3d( XFORM_ARGS );
00049 
00050 #define ASSIGN_XFORM_GROUP( pfx, sz )                   \
00051    _mesa_transform_tab[sz][MATRIX_GENERAL] =                \
00052       _mesa_##pfx##_transform_points##sz##_general;         \
00053    _mesa_transform_tab[sz][MATRIX_IDENTITY] =               \
00054       _mesa_##pfx##_transform_points##sz##_identity;            \
00055    _mesa_transform_tab[sz][MATRIX_3D_NO_ROT] =              \
00056       _mesa_##pfx##_transform_points##sz##_3d_no_rot;           \
00057    _mesa_transform_tab[sz][MATRIX_PERSPECTIVE] =            \
00058       _mesa_##pfx##_transform_points##sz##_perspective;         \
00059    _mesa_transform_tab[sz][MATRIX_2D] =                 \
00060       _mesa_##pfx##_transform_points##sz##_2d;              \
00061    _mesa_transform_tab[sz][MATRIX_2D_NO_ROT] =              \
00062       _mesa_##pfx##_transform_points##sz##_2d_no_rot;           \
00063    _mesa_transform_tab[sz][MATRIX_3D] =                 \
00064       _mesa_##pfx##_transform_points##sz##_3d;
00065 
00066 
00067 /* =============================================================
00068  * Normal transformation function declarations:
00069  */
00070 
00071 #define NORM_ARGS   const GLmatrix *mat,                \
00072             GLfloat scale,                  \
00073             const GLvector4f *in,               \
00074             const GLfloat *lengths,             \
00075             GLvector4f *dest
00076 
00077 #define DECLARE_NORM_GROUP( pfx ) \
00078 extern void _ASMAPI _mesa_##pfx##_rescale_normals( NORM_ARGS );             \
00079 extern void _ASMAPI _mesa_##pfx##_normalize_normals( NORM_ARGS );           \
00080 extern void _ASMAPI _mesa_##pfx##_transform_normals( NORM_ARGS );           \
00081 extern void _ASMAPI _mesa_##pfx##_transform_normals_no_rot( NORM_ARGS );        \
00082 extern void _ASMAPI _mesa_##pfx##_transform_rescale_normals( NORM_ARGS );       \
00083 extern void _ASMAPI _mesa_##pfx##_transform_rescale_normals_no_rot( NORM_ARGS );    \
00084 extern void _ASMAPI _mesa_##pfx##_transform_normalize_normals( NORM_ARGS );     \
00085 extern void _ASMAPI _mesa_##pfx##_transform_normalize_normals_no_rot( NORM_ARGS );
00086 
00087 #define ASSIGN_NORM_GROUP( pfx )                    \
00088    _mesa_normal_tab[NORM_RESCALE] =                 \
00089       _mesa_##pfx##_rescale_normals;                    \
00090    _mesa_normal_tab[NORM_NORMALIZE] =                   \
00091       _mesa_##pfx##_normalize_normals;                  \
00092    _mesa_normal_tab[NORM_TRANSFORM] =                   \
00093       _mesa_##pfx##_transform_normals;                  \
00094    _mesa_normal_tab[NORM_TRANSFORM_NO_ROT] =                \
00095       _mesa_##pfx##_transform_normals_no_rot;               \
00096    _mesa_normal_tab[NORM_TRANSFORM | NORM_RESCALE] =            \
00097       _mesa_##pfx##_transform_rescale_normals;              \
00098    _mesa_normal_tab[NORM_TRANSFORM_NO_ROT | NORM_RESCALE] =     \
00099       _mesa_##pfx##_transform_rescale_normals_no_rot;           \
00100    _mesa_normal_tab[NORM_TRANSFORM | NORM_NORMALIZE] =          \
00101       _mesa_##pfx##_transform_normalize_normals;            \
00102    _mesa_normal_tab[NORM_TRANSFORM_NO_ROT | NORM_NORMALIZE] =       \
00103       _mesa_##pfx##_transform_normalize_normals_no_rot;
00104 
00105 
00106 #endif

Generated on Sun May 27 2012 04:20:49 for ReactOS by doxygen 1.7.6.1

ReactOS is a registered trademark or a trademark of ReactOS Foundation in the United States and other countries.