Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

calc_spline(3alleg4) [debian man page]

calc_spline(3alleg4)						  Allegro manual					      calc_spline(3alleg4)

NAME
calc_spline - Calculates a series of values along a Bezier spline. Allegro game programming library. SYNOPSIS
#include <allegro.h> void calc_spline(const int points[8], int npts, int *x, int *y); DESCRIPTION
Calculates a series of npts values along a Bezier spline, storing them in the output x and y arrays. The Bezier curve is specified by the four x/y control points in the points array: points[0] and points[1] contain the coordinates of the first control point, points[2] and points[3] are the second point, etc. Control points 0 and 3 are the ends of the spline, and points 1 and 2 are guides. The curve probably won't pass through points 1 and 2, but they affect the shape of the curve between points 0 and 3 (the lines p0-p1 and p2-p3 are tangents to the spline). The easiest way to think of it is that the curve starts at p0, heading in the direction of p1, but curves round so that it arrives at p3 from the direction of p2. In addition to their role as graphics primitives, spline curves can be useful for constructing smooth paths around a series of control points, as in exspline.c. SEE ALSO
spline(3alleg4), exspline(3alleg4) Allegro version 4.4.2 calc_spline(3alleg4)

Check Out this Related Man Page

calc_spline(3alleg4)						  Allegro manual					      calc_spline(3alleg4)

NAME
calc_spline - Calculates a series of values along a Bezier spline. Allegro game programming library. SYNOPSIS
#include <allegro.h> void calc_spline(const int points[8], int npts, int *x, int *y); DESCRIPTION
Calculates a series of npts values along a Bezier spline, storing them in the output x and y arrays. The Bezier curve is specified by the four x/y control points in the points array: points[0] and points[1] contain the coordinates of the first control point, points[2] and points[3] are the second point, etc. Control points 0 and 3 are the ends of the spline, and points 1 and 2 are guides. The curve probably won't pass through points 1 and 2, but they affect the shape of the curve between points 0 and 3 (the lines p0-p1 and p2-p3 are tangents to the spline). The easiest way to think of it is that the curve starts at p0, heading in the direction of p1, but curves round so that it arrives at p3 from the direction of p2. In addition to their role as graphics primitives, spline curves can be useful for constructing smooth paths around a series of control points, as in exspline.c. SEE ALSO
spline(3alleg4), exspline(3alleg4) Allegro version 4.4.2 calc_spline(3alleg4)
Man Page

14 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Lables in UNIX

Hi all, I am relatively new to UNIX coding so please pardon the potentially silly question. I am running on AIX v4. I have a large batch script that I have scheduled to run monthly. When the script falls over, I have to manually comment out all of the preceding steps before I can rerun the... (7 Replies)
Discussion started by: jthomas
7 Replies

2. Programming

clearing breakpoints using dbx v 7.2.1

Im unsure of how to clear break points using dbx v7.2.1 Ive tried using delete linenumber of breakpoint however this does not seem to work. Could anyone point me in the correct direction ? regards (0 Replies)
Discussion started by: JamesGoh
0 Replies

3. Shell Programming and Scripting

to extarct data points

suppose u have a file which consist of many data points separated by asterisk Question is to extract third part in each line . 0.0002*0.003*-0.93939*0.0202*0.322*0.3332*0.2222*0.22020 0.003*0.3333*0.33322*-0.2220*0.3030*0.2222*0.3331*-0.3030 0.0393*0.3039*-0.03038*0.033*0.4033*0.30384*0.4048... (5 Replies)
Discussion started by: cdfd123
5 Replies

4. Post Here to Contact Site Administrators and Moderators

Points?

Has any thought been given to assigning points to threads much in the way the HP ITRC forums do? This might not be possible, just a thought. (1 Reply)
Discussion started by: candlejack
1 Replies

5. Programming

series of combinations

HI I have a series(sorted), which i require to create combinations. I am not getting the good code for doing this. My series should generate the following combinations... Please help me in getting this in C++. Thanks for your help. A: A A B: A B A B A B C: A ... (1 Reply)
Discussion started by: rameshmelam
1 Replies

6. Shell Programming and Scripting

Interpolating on a line between to points

I have two points which represent the start and end points of a line. I need to interpolate a number of points on the line between the two points. Point 1: x = 455989.0 y = 8673453.4 Point 2: x = 283957.6 y = 8691250.1 The two points I have are coordinates given in UTM format. x... (3 Replies)
Discussion started by: mattings
3 Replies

7. UNIX for Dummies Questions & Answers

matching points in Gnuplot

Does anyone know how can one draw lines between 2 sets of data for the same point. let's say that the three points (x1,y1) = (1,2) (4,5) (8.9) became: (x2,y2) = (3,6) (6,4) (4, 0) so if I want to plot these points and match every (x1,y1) with the corresponding (x2,y2), how can I do it?... (3 Replies)
Discussion started by: cosmologist
3 Replies

8. Programming

C program for generating loophole series

C PROGRAM TO GENERATE THE FOLLOWING SERIES CALLED LOOPHOLE SERIES:- 3,5,53,13,19,7,19,13,53,5,3 How do i do it? Can somebody explain what is Loophole series and its applications? (2 Replies)
Discussion started by: vkca
2 Replies

9. Shell Programming and Scripting

Determination n points between two coordinates

Hi guys. Can anyone tell me how to determine points between two coardinates. For example: Which type of command line gives me 50 points between (8, -5, 7) and (2, 6, 9) points Thanks (5 Replies)
Discussion started by: rpf
5 Replies

10. UNIX for Dummies Questions & Answers

interpolting (spline)

Hi, Does anyone know how I can do an interpolation (with spline) using awk or any other way? This is part of the sample: 1 1.36064 1.09999 1.44 1.20005 1.84 1.30005 2.0416 1.39997 2.24 1.49993 2.4416 1.6 2.6592 1.7001 2.88 1.79986 3.1392 1.90006 3.36 Thanks! (2 Replies)
Discussion started by: cosmologist
2 Replies

11. Shell Programming and Scripting

loop for determination of number of points in a enclosed area

Hi Friends, I am trying to find coordinates within three points by using a for loop. For example: I want to find points within the triangular area enclosed by (1,2,3), (4,5,6) and (7,8,9) points. I want to create a mesh in a triangle and I should know the coordinates of points. Best... (4 Replies)
Discussion started by: rpf
4 Replies

12. Shell Programming and Scripting

How to sort this?

x:y field from 0:0 i have 20 points in every direction so it's -20 to +20 X and -20 to +20 Y that's 1681 x:y points now i need to sort them like: 0:0 0:1 1:1 1:0 1:-1 0:-1 -1:-1 -1:0 -1:1 0:2 1:2 2:2etc every 1 point square from the middle which algorithm is better? (10 Replies)
Discussion started by: tip78
10 Replies

13. Slackware

Grace and plotting

I am making mathematical graphics in grace, all is working, but my curves are not totally smooth,..i have equal problem in gnuplot,... can i do anything??:confused: (4 Replies)
Discussion started by: gitac
4 Replies

14. Shell Programming and Scripting

How many studies have unequal values for each pair?

I have several Studies (s) which has points (p) having Values (v). My goal is to determine for each pair of points, how many studies have different values ( if available ). Study Point Value 1 p1 value1 1 p2 value2 1 p3 value1 1 p4 value3 1 p5 value3 2 p2 value1 2 p4 value1 3 p1 value1... (5 Replies)
Discussion started by: senhia83
5 Replies