Changeset 128
- Timestamp:
- Nov 10, 2003, 4:16:38 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
ttyvaders/trunk/libee/line.c
r104 r128 41 41 static void draw_thin_line(struct line*); 42 42 43 /** 44 * \brief Draw a line on the screen using the given character. 45 * 46 * \param x1 X coordinate of the first point. 47 * \param y1 Y coordinate of the first point. 48 * \param x2 X coordinate of the second point. 49 * \param y2 Y coordinate of the second point. 50 * \param c Character to draw the line with. 51 * \return nothing 52 */ 43 53 void ee_draw_line(int x1, int y1, int x2, int y2, char c) 44 54 { … … 53 63 } 54 64 65 /** 66 * \brief Draw a thin line on the screen, using ASCII art. 67 * 68 * \param x1 X coordinate of the first point. 69 * \param y1 Y coordinate of the first point. 70 * \param x2 X coordinate of the second point. 71 * \param y2 Y coordinate of the second point. 72 * \return nothing 73 */ 55 74 void ee_draw_thin_line(int x1, int y1, int x2, int y2) 56 75 { … … 64 83 } 65 84 85 /** 86 * \brief Generic Cohen-Sutherland line clipping function. 87 * 88 * \param s a line structure 89 * \return nothing 90 */ 66 91 static void clip_line(struct line* s) 67 92 { … … 115 140 } 116 141 142 /** 143 * \brief Helper function for clip_line(). 144 * 145 * \param x X coordinate of the point. 146 * \param y Y coordinate of the point. 147 * \return b The clipping bits for the given point. 148 */ 117 149 static uint8_t clip_bits(int x, int y) 118 150 { … … 132 164 } 133 165 166 /** 167 * \brief Solid line drawing function, using Bresenham's mid-point line 168 * scan-conversion algorithm. 169 * 170 * \param s a line structure 171 * \return nothing 172 */ 134 173 static void draw_solid_line(struct line* s) 135 174 { … … 194 233 } 195 234 235 /** 236 * \brief Thin line drawing function, using Bresenham's mid-point line 237 * scan-conversion algorithm and ASCII art graphics. 238 * 239 * \param s a line structure 240 * \return nothing 241 */ 196 242 static void draw_thin_line(struct line* s) 197 243 {
Note: See TracChangeset
for help on using the changeset viewer.