00001 /* 00002 * Copyright © 2010 Ian D. Romanick 00003 * 00004 * Permission is hereby granted, free of charge, to any person obtaining a 00005 * copy of this software and associated documentation files (the "Software"), 00006 * to deal in the Software without restriction, including without limitation 00007 * the rights to use, copy, modify, merge, publish, distribute, sublicense, 00008 * and/or sell copies of the Software, and to permit persons to whom the 00009 * Software is furnished to do so, subject to the following conditions: 00010 * 00011 * The above copyright notice and this permission notice (including the next 00012 * paragraph) shall be included in all copies or substantial portions of the 00013 * Software. 00014 * 00015 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 00016 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 00017 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 00018 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 00019 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 00020 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 00021 * DEALINGS IN THE SOFTWARE. 00022 */ 00023 00024 #include "system.h" 00025 #include "glu3.h" 00026 00027 #if defined(__cplusplus) 00028 extern "C" { 00029 #endif 00030 00031 typedef void (revolve_cb)(void *data, const GLUvec4 *position, 00032 const GLUvec4 *normal, const GLUvec4 *tangent, 00033 const GLUvec4 *uv); 00034 00059 extern void 00060 revolve(const GLUvec4 *points, const GLUvec4 *normals, const float *u, 00061 unsigned num_points, 00062 const GLUvec4 *axis, 00063 unsigned steps, float start_angle, float end_angle, 00064 revolve_cb *cb, void *data); 00065 00066 extern void 00067 generate_sphere(double radius, unsigned slices, unsigned stacks, 00068 bool normals_point_out, revolve_cb *cb, void *data); 00069 00070 #ifdef __cplusplus 00071 }; 00072 #endif