52 virtual int Size()
const=0;
53 virtual T Index(
float time,
int p)
const=0;
70 float Length()
const {
return cloud.Length(); }
71 int Size()
const {
return cloud.Size(); }
74 Point pp = cloud.Index(time, p);
92 int size = arr.Size();
94 for(
int i=0;i<
size;i++)
96 length += arr.Index(i)->Size();
102 int size = arr.Size();
104 for(
int i=0;i<
size;i++)
106 int oldlength = length;
107 length += arr.Index(i)->Size();
110 return arr.Index(i)->Index(time-oldlength);
113 return Point(0.0,0.0,0.0);
125 int size = arr.Size();
127 for(
int i=0;i<
size;i++)
129 length += arr.Index(i)->Length();
135 int size = arr.Size();
137 for(
int i=0;i<
size;i++)
139 num = std::min(
num, arr.Index(i)->Size());
145 int size = arr.Size();
147 Point pp(0.0,0.0,0.0);
148 for(
int i=0;i<
size;i++)
150 int oldlength = length;
151 length += arr.Index(i)->Length();
154 return pp+arr.Index(i)->Index(time-oldlength, p);
156 pp += arr.Index(i)->Index(arr.Index(i)->Length(), p);
168 float Size()
const {
return cloud.Length(); }
171 return cloud.Index(time, p);
187 return paths.Index(time, i);
198 int NumPoints()
const {
return std::min(c1.Size(), c2.Size()); }
202 Point p1 = c1.Index(p);
203 Point p2 = c2.Index(p);
204 float val = time / length;
218 int Size()
const {
return std::min(c1.Size(), c2.Size()); }
238 int size = arr.Size();
240 for(
int i=0;i<
size;i++)
242 length += arr.Index(i)->Length();
248 int size = arr.Size();
250 for(
int i=0;i<
size;i++)
252 num = std::min(
num, arr.Index(i)->Size());
258 int size = arr.Size();
261 for(
int i=0;i<
size;i++)
263 int oldlength = length;
264 length += arr.Index(i)->Length();
267 return m*arr.Index(i)->Index(time-oldlength, p);
269 m = m * arr.Index(i)->Index(arr.Index(i)->Length(),p);
283 int size = curves.Size();
284 float num = 999999.0;
285 for(
int i=0;i<
size;i++)
287 num = std::min(
num, curves.Index(i)->Size());
293 return curves.Size();
297 return curves.Index(p)->Index(time);
309 arr.push_back(&inter);
312 float Length()
const {
return seq.Length(); }
313 int Size()
const {
return seq.Size(); }
314 Matrix Index(
float time,
int p)
const {
return seq.Index(time,p); }
328 int Size()
const {
return points.Size()-1; }
336 Point2d p = points.Index(func);
339 float z_i =
z_i_f(z_0, func);
340 Point2d p2 = points.Index(func+1);
343 float z_i_1 =
z_i_1_f(z_i, func);
344 float S_i = y_i + z_i*(x-x_i) + (z_i_1 - z_i)/2.0/(x_i_1-x_i) * (x-x_i)*(x-x_i);
350 Point2d p2 = points.Index(i+1);
351 return -z_i + 2.0*(p2.
y-p.
y)/(p2.
x-p.
x);
353 float z_i_f(
float z_0,
int ii)
const
356 for(
int i=1;i<ii;i++)
375 int size=coll.Size()-1;
376 for(
int i=0;i<
size;i++)
378 if (x>=coll.Index(i).x && x<coll.Index(i+1).x)
380 return func.Index(i)->Index(x);
394 int Size()
const {
return std::min(coll.Size(), arr.Size()); }
400 p.
y = coll.Index(i).x;
402 p.
y = coll.Index(i).y;
404 p.
y = coll.Index(i).z;
420 SplineCurve(PointCollection &coll, FloatArray &arr) : arr(arr), x(coll, arr, 0), y(coll,arr,1), z(coll,arr,2), sx(x), sy(y), sz(z) { }
421 float Size()
const {
return arr.
Index(arr.Size()-1) - arr.Index(0); }
422 Point
Index(
float t)
const
437 SplineInterpolation sx;
438 SplineInterpolation sy;
439 SplineInterpolation sz;
446 CircleMatrixPath(
float x1,
float x2,
int count,
float time) : circle(x1), circle2(x2), sample(circle, count), sample2(circle2, count), im(sample, sample2, time) { }
447 float Length()
const {
return im.Length(); }
448 int Size()
const {
return im.Size(); }
451 Matrix m = im.Index(time,p);
468 int Size()
const {
return arr.Size(); }
486 virtual float Dist(
int p1,
int p2)
const=0;
492 float Dist(
int p1,
int p2)
const
494 Point r = coll.Index(p1);
495 Point r2 = coll.Index(p2);
496 return (r2-r).
Dist();
505 float Dist(
int p1,
int p2)
const
507 return arr.Index(p2)-arr.Index(p1);
514class LinearInterpolation :
public CurveIn3d
517 LinearInterpolation(PointCollection &coll) : coll(coll),
d(coll), dist(
d) { }
518 LinearInterpolation(PointCollection &coll, InterpolationDistance &dist) : coll(coll),
d(coll), dist(dist) { }
519 Point
Index(
float pos)
const
524 int size = coll.Size()-1;
527 d = dist.Dist(i,i+1);
529 if (length>pos)
break;
534 Point px = Point((1.0-pos)*Vector(coll.Index(i)) + pos*Vector(coll.Index(i+1)));
540 for(
int i=0;i<coll.Size()-1;i++)
542 length += dist.Dist(i,i+1);
555 PointCollection &coll;
557 InterpolationDistance &dist;
564 float Length()
const {
return arr.Index(0)->Size(); }
565 int Size()
const {
return arr.Size(); }
568 return arr.Index(p)->Index(time);
578 SelectPoints(Array<int, PointCollection*> &arr,
int select) : arr(arr),
select(
select) { }
579 int Size()
const {
return arr.
Size(); }
580 Point
Index(
int index)
const
582 return arr.Index(index)->Index(
select);
585 Array<int, PointCollection*> &arr;
596 float Length()
const {
return parallel.Length(); }
597 int Size()
const {
return parallel.Size(); }
600 return parallel.Index(time,p);
604 struct LM :
public Array<int, CurveIn3d*>
612 CurveIn3d *Index(
int i)
const
642 int Size()
const {
return arr.Size(); }
648 pc.coll = arr.
Index(i);
653 int size = arr.Size();
655 for(
int i=0;i<
size;i++)
657 maxsize = std::max(maxsize, arr.Index(i)->Size());
666 if (i < coll->
Size())
667 return coll->Index(i);
669 return coll->Index(0);
P func(int c, EveryApi &ev)
Definition test.cpp:59
VBOUpdate
Definition Effect.hh:10676
Time< Point > TimedPoint
Definition Event.hh:34
void DrawVBO(TimedMatrixPaths &paths, float time, VBOState &vbostate, VBOUpdate u)
Definition Event.cc:27
Time< Vector > TimedVector
Definition Event.hh:35
Time< Matrix > TimedMatrix
Definition Event.hh:36
long double select(long double n, int k)
Definition Math2.cc:413
virtual float Size() const=0
BoxCollectionFromPaths(TimedMatrixPaths &paths, float time)
Definition Event.hh:180
int Size() const
Definition Event.hh:181
Matrix Index(int i) const
Definition Event.hh:185
Definition Effect.hh:5476
int Size() const
Definition Event.hh:394
ChooseXYZ(PointCollection &coll, FloatArray &arr, int xyz)
Definition Event.hh:393
Point2d Index(int i) const
Definition Event.hh:395
Definition Effect.hh:1718
int Size() const
Definition Event.hh:448
float Length() const
Definition Event.hh:447
CircleMatrixPath(float x1, float x2, int count, float time)
Definition Event.hh:446
Matrix Index(float time, int p) const
Definition Event.hh:449
Matrix Index(float time, int p) const
Definition Event.hh:314
float Length() const
Definition Event.hh:312
int Size() const
Definition Event.hh:313
ConnectMatrixPaths(TimedMatrixPaths &c1, TimedMatrixPaths &c2, float length)
Definition Event.hh:306
Dist1(PointCollection &coll)
Definition Event.hh:491
float Dist(int p1, int p2) const
Definition Event.hh:492
Dist2(FloatArray &arr)
Definition Event.hh:504
float Dist(int p1, int p2) const
Definition Event.hh:505
Definition Effect.hh:2039
virtual B Index(A a) const =0
Matrix Index(float time, int p) const
Definition Event.hh:219
int Size() const
Definition Event.hh:218
InterpolateMatrixes(BoxCollection &c1, BoxCollection &c2, float length)
Definition Event.hh:216
float Length() const
Definition Event.hh:217
float Length() const
Definition Event.hh:199
InterpolatePoints(PointCollection &c1, PointCollection &c2, float length)
Definition Event.hh:197
int NumPoints() const
Definition Event.hh:198
Point Index(float time, int p) const
Definition Event.hh:200
virtual float Dist(int p1, int p2) const =0
Point Index(float time, int p) const
Definition Event.hh:598
float Length() const
Definition Event.hh:596
LinearMovement(Array< int, PointCollection * > &arr, FloatArray &time)
Definition Event.hh:594
int Size() const
Definition Event.hh:597
friend struct LM
Definition Event.hh:624
Definition VectorTools.hh:279
static Matrix Translate(float x, float y, float z)
Definition VectorTools.cc:547
static Matrix Identity()
Definition VectorTools.cc:487
static Matrix Interpolate(const Matrix &m1, const Matrix &m2, float t)
Definition VectorTools.cc:983
Point Index(float time, int p) const
Definition Event.hh:566
float Length() const
Definition Event.hh:564
int Size() const
Definition Event.hh:565
ParallelCurvesPoint(Array< int, CurveIn3d * > &arr)
Definition Event.hh:563
ParallelCurves(Array< int, MatrixCurve * > &curves)
Definition Event.hh:280
Matrix Index(float time, int p) const
Definition Event.hh:295
int Size() const
Definition Event.hh:291
float Length() const
Definition Event.hh:281
virtual int Size() const =0
virtual ~Paths()
Definition Event.hh:50
virtual float Length() const =0
virtual T Index(float time, int p) const =0
Definition Shader.hh:1251
int Size() const
Definition Event.hh:133
float Length() const
Definition Event.hh:123
Point Index(float time, int p) const
Definition Event.hh:143
PointCloudSequence(Array< int, TimedPointCloud * > &arr)
Definition Event.hh:122
Definition Effect.hh:2663
Definition Effect.hh:2456
Definition Effect.hh:5822
int Size() const
Definition Event.hh:642
SizeCollections(Array< int, PointCollection * > &arr)
Definition Event.hh:638
int MaxSize() const
Definition Event.hh:651
PointCollection * Index(int i) const
Definition Event.hh:643
SplineCurves(Array< int, PointCollection * > &arr, FloatArray &arr2)
Definition Event.hh:467
int Size() const
Definition Event.hh:468
CurveIn3d * Index(int i) const
Definition Event.hh:469
SplineFunctions(const PointCollection2d &points, float z_0)
Definition Event.hh:327
float Index(float x) const
Definition Event.hh:334
float z_i_f(float z_0, int ii) const
Definition Event.hh:353
int Size() const
Definition Event.hh:328
float z_i_1_f(float z_i, int i) const
Definition Event.hh:347
const Function< float, float > * Index(int i) const
Definition Event.hh:329
SplineInterpolation(PointCollection2d &coll)
Definition Event.hh:372
float Index(float x) const
Definition Event.hh:373
float Size() const
Definition Event.hh:168
TimeLineFromPointCloud(TimedPointCloud &cloud, int p)
Definition Event.hh:167
Point Index(float time) const
Definition Event.hh:169
TimeLineSequence(Array< int, TimeLine * > &arr)
Definition Event.hh:89
float Size() const
Definition Event.hh:90
Point Index(float time) const
Definition Event.hh:100
Point o
Definition Event.hh:32
float time
Definition Event.hh:31
int Size() const
Definition Event.hh:246
Matrix Index(float time, int p) const
Definition Event.hh:256
float Length() const
Definition Event.hh:236
TimedMatrixSequence(Array< int, TimedMatrixPaths * > &arr)
Definition Event.hh:235
TranslatePaths(TimedPointCloud &cloud)
Definition Event.hh:69
Matrix Index(float time, int p) const
Definition Event.hh:72
int Size() const
Definition Event.hh:71
float Length() const
Definition Event.hh:70
Definition Effect.hh:10694
Definition Effect.hh:1122
Definition VectorTools.hh:125
d
Definition meshpage.php:3895
n< br > font size
Definition meshpage.php:3536
Definition VectorTools.hh:910
float x
Definition VectorTools.hh:911
float y
Definition VectorTools.hh:911
float x
Definition Parser.cc:60
float Dist() const
Definition VectorTools.cc:150
float y
Definition Parser.cc:60
float z
Definition Parser.cc:60
PointCollection * coll
Definition Event.hh:671
int size
Definition Event.hh:672
int Size() const
Definition Event.hh:663
Point Index(int i) const
Definition Event.hh:664
num
Definition view.php:2821