Revision d7bbef2f
Added by Distorted Admin over 9 years ago
| src/main/java/org/distorted/library/DistortedObject.java | ||
|---|---|---|
| 374 | 374 |
/** |
| 375 | 375 |
* Moves the Object by a vector that changes in time as interpolated by the Interpolator. |
| 376 | 376 |
* |
| 377 |
* @param di a 3-dimensional Interpolator which at any given time will return a Float3D
|
|
| 377 |
* @param di 3-dimensional Interpolator which at any given time will return a Float3D |
|
| 378 | 378 |
* representing the current coordinates of the vector we want to move the Object with. |
| 379 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 379 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 380 | 380 |
*/ |
| 381 | 381 |
public long move(Interpolator3D di) |
| 382 | 382 |
{
|
| ... | ... | |
| 387 | 387 |
/** |
| 388 | 388 |
* Moves the Bitmap by a vector that smoothly changes from (0,0,0) to (x,y,z). |
| 389 | 389 |
* |
| 390 |
* @param x The x-coordinate of the vector we want to move the Object with. |
|
| 391 |
* @param y The y-coordinate of the vector we want to move the Object with. |
|
| 392 |
* @param z The z-coordinate of the vector we want to move the Object with. |
|
| 390 |
* @param x The x-coordinate of the vector we want to move the Object with.
|
|
| 391 |
* @param y The y-coordinate of the vector we want to move the Object with.
|
|
| 392 |
* @param z The z-coordinate of the vector we want to move the Object with.
|
|
| 393 | 393 |
* @param duration The time, in milliseconds, it takes to complete the movement. |
| 394 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 394 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 395 | 395 |
*/ |
| 396 | 396 |
public long move(float x,float y,float z, int duration) |
| 397 | 397 |
{
|
| ... | ... | |
| 411 | 411 |
* @param x The x-coordinate of the vector we want to move the Object with. |
| 412 | 412 |
* @param y The y-coordinate of the vector we want to move the Object with. |
| 413 | 413 |
* @param z The z-coordinate of the vector we want to move the Object with. |
| 414 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 414 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 415 | 415 |
*/ |
| 416 | 416 |
public long move(float x,float y,float z) |
| 417 | 417 |
{
|
| ... | ... | |
| 423 | 423 |
/** |
| 424 | 424 |
* Scales the Object by factors that change in time as returned by the Interpolator. |
| 425 | 425 |
* |
| 426 |
* @param di a 3-dimensional Interpolator which at any given time returns a Float3D
|
|
| 426 |
* @param di 3-dimensional Interpolator which at any given time returns a Float3D |
|
| 427 | 427 |
* representing the current x- , y- and z- scale factors. |
| 428 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 428 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 429 | 429 |
*/ |
| 430 | 430 |
public long scale(Interpolator3D di) |
| 431 | 431 |
{
|
| ... | ... | |
| 437 | 437 |
* Scales the Object by a factor that smoothly changes from (1,1,1) at time 0 to (xscale,yscale,zscale) |
| 438 | 438 |
* after 'duration' milliseconds. |
| 439 | 439 |
* |
| 440 |
* @param xscale After time 'duration' passes, Bitmap's width will get multiplied by xscale; e.g. if |
|
| 441 |
* xscale=2, after 'duration' milliseconds the Object will become twice broader. |
|
| 442 |
* @param yscale factor to scale Object's height with.
|
|
| 443 |
* @param zscale factor to scale Object's depth with.
|
|
| 440 |
* @param xscale After time 'duration' passes, Bitmap's width will get multiplied by xscale; e.g. if
|
|
| 441 |
* xscale=2, after 'duration' milliseconds the Object will become twice broader.
|
|
| 442 |
* @param yscale Factor to scale Object's height with.
|
|
| 443 |
* @param zscale Factor to scale Object's depth with.
|
|
| 444 | 444 |
* @param duration Time, in milliseconds, it takes to interpolate to the full (xscale,yscale,zscale) scaling factors. |
| 445 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 445 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 446 | 446 |
*/ |
| 447 | 447 |
public long scale(float xscale,float yscale,float zscale, int duration) |
| 448 | 448 |
{
|
| ... | ... | |
| 463 | 463 |
* xscale=2, the Object immediately becomes twice broader. |
| 464 | 464 |
* @param yscale factor to scale Object's height with. |
| 465 | 465 |
* @param zscale factor to scale Object's depth with. |
| 466 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 466 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 467 | 467 |
*/ |
| 468 | 468 |
public long scale(float xscale,float yscale,float zscale) |
| 469 | 469 |
{
|
| ... | ... | |
| 474 | 474 |
/** |
| 475 | 475 |
* Convenience function - scale the Object by the same factor in all 3 dimensions. |
| 476 | 476 |
* |
| 477 |
* @param scale all 3 Object's dimensions gets multiplied by this factor; e.g. if
|
|
| 477 |
* @param scale all 3 Object's dimensions get multiplied by this factor; e.g. if |
|
| 478 | 478 |
* scale=2, the Object immediately becomes twice larger. |
| 479 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 479 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 480 | 480 |
*/ |
| 481 | 481 |
public long scale(float scale) |
| 482 | 482 |
{
|
| ... | ... | |
| 492 | 492 |
* the rotation |
| 493 | 493 |
* @param v 4-dimensional Interpolator which at any given time will return a Float4D |
| 494 | 494 |
* representing the current rotation in the (angle,axisX,axisY,axisY) form. |
| 495 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 495 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 496 | 496 |
*/ |
| 497 | 497 |
public long rotate(Interpolator3D i, Interpolator4D v) |
| 498 | 498 |
{
|
| ... | ... | |
| 503 | 503 |
/** |
| 504 | 504 |
* Rotates the Object around a static point, with angle and axis that change in time. |
| 505 | 505 |
* |
| 506 |
* @param p the center of the rotation
|
|
| 507 |
* @param v 4-dimensional Interpolator which at any given time will return a Float4D |
|
| 508 |
* representing the current rotation in the (angle,axisX,axisY,axisY) form. |
|
| 509 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 506 |
* @param point Center of the rotation
|
|
| 507 |
* @param v 4-dimensional Interpolator which at any given time will return a Float4D
|
|
| 508 |
* representing the current rotation in the (angle,axisX,axisY,axisY) form.
|
|
| 509 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 510 | 510 |
*/ |
| 511 | 511 |
public long rotate(Float3D point, Interpolator4D v) |
| 512 | 512 |
{
|
| ... | ... | |
| 515 | 515 |
|
| 516 | 516 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
| 517 | 517 |
/** |
| 518 |
* Rotates the Object around a static point, with angle that changes in time. |
|
| 518 |
* Rotates the Object around a static point, with angle that changes in time, around axis |
|
| 519 |
* (axisX, axisY, axisZ). |
|
| 519 | 520 |
* |
| 520 |
* @param p the center of the rotation |
|
| 521 |
* @param v 1-dimensional Interpolator which at any given time will return the current rotation |
|
| 522 |
* angle. |
|
| 523 |
* @param (axisX, axisY, axisZ) the rotation vector |
|
| 524 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 521 |
* @param point Center of the rotation |
|
| 522 |
* @param v 1-dimensional Interpolator which at any given time will return the current rotation |
|
| 523 |
* angle. |
|
| 524 |
* @param axisX Rotation vector: x-coordinate |
|
| 525 |
* @param axisY Rotation vector: y-coordinate |
|
| 526 |
* @param axisZ Rotation vector: z-coordinate |
|
| 527 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 525 | 528 |
*/ |
| 526 | 529 |
public long rotate(Float3D point, Interpolator1D v, float axisX, float axisY, float axisZ) |
| 527 | 530 |
{
|
| ... | ... | |
| 536 | 539 |
* @param i 3-dimensional Interpolator which at any given time will return the current center |
| 537 | 540 |
* of the rotation. |
| 538 | 541 |
* @param a 1-dimensional Interpolator which returns the current rotation angle. |
| 539 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 542 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 540 | 543 |
*/ |
| 541 | 544 |
public long rotate(Interpolator3D i, Interpolator1D a) |
| 542 | 545 |
{
|
| ... | ... | |
| 548 | 551 |
* Rotates the Object around a constant point, with angle that changes in time. |
| 549 | 552 |
* Axis of rotation is the vector (0,0,1), i.e. a vector normal to the screen surface. |
| 550 | 553 |
* |
| 551 |
* @param p Coordinates of the Point we are rotating around. |
|
| 552 |
* @param angle The angle, in degrees, that we want to rotate the Bitmap to.
|
|
| 554 |
* @param point Coordinates of the Point we are rotating around.
|
|
| 555 |
* @param angle Angle that we want to rotate the Bitmap to. Unit: degrees
|
|
| 553 | 556 |
* @param duration Time, in milliseconds, it takes to complete one rotation from 0 to 'angle' degrees. |
| 554 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 557 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 555 | 558 |
*/ |
| 556 | 559 |
public long rotate(Float3D point, int angle, int duration) |
| 557 | 560 |
{
|
| ... | ... | |
| 569 | 572 |
* Rotates the Object immediately by 'angle' degrees around point p. |
| 570 | 573 |
* Axis of rotation is given by the last 3 floats. |
| 571 | 574 |
* |
| 572 |
* @param p Coordinates of the Point we are rotating around. |
|
| 573 |
* @param angle The angle, in degrees, that we want to rotate the Bitmap to. |
|
| 574 |
* @param (axisX,axisY,axisZ) - axis of rotation. |
|
| 575 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 575 |
* @param point Coordinates of the Point we are rotating around. |
|
| 576 |
* @param angle Angle that we want to rotate the Bitmap to. Unit: degrees |
|
| 577 |
* @param axisX Axis of rotation: x-coordinate |
|
| 578 |
* @param axisY Axis of rotation: y-coordinate |
|
| 579 |
* @param axisZ Axis of rotation: z-coordinate |
|
| 580 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 576 | 581 |
*/ |
| 577 | 582 |
public long rotate(Float3D point, float angle, float axisX, float axisY, float axisZ) |
| 578 | 583 |
{
|
| ... | ... | |
| 583 | 588 |
/** |
| 584 | 589 |
* Rotates the Object immediately by 'angle' degrees around point p. |
| 585 | 590 |
* |
| 586 |
* @param p Coordinates of the Point we are rotating around.
|
|
| 587 |
* @param angle The angle, in degrees, that we want to rotate the Bitmap to.
|
|
| 591 |
* @param point Coordinates of the Point we are rotating around.
|
|
| 592 |
* @param angle The angle that we want to rotate the Bitmap to. Unit: degrees
|
|
| 588 | 593 |
* @return ID of the effect added, or -1 if we failed to add one. |
| 589 | 594 |
*/ |
| 590 | 595 |
public long rotate(Float3D point, int angle) |
| ... | ... | |
| 597 | 602 |
/** |
| 598 | 603 |
* Rotates the Object immediately by quaternion (qX,qY,qZ,qW). |
| 599 | 604 |
* |
| 600 |
* @param p Coordinates of the Point we are rotating around. |
|
| 601 |
* @param (qX,qY,qZ,qW) - the quaternion. |
|
| 602 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 605 |
* @param point Coordinates of the Point we are rotating around. |
|
| 606 |
* @param qX Quaternion: x-coordinate |
|
| 607 |
* @param qY Quaternion: y-coordinate |
|
| 608 |
* @param qZ Quaternion: z-coordinate |
|
| 609 |
* @param qW Quaternion: w-coordinate |
|
| 610 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 603 | 611 |
*/ |
| 604 | 612 |
public long quaternion(Float3D point, float qX, float qY, float qZ, float qW) |
| 605 | 613 |
{
|
| ... | ... | |
| 610 | 618 |
/** |
| 611 | 619 |
* Rotates the Object by a quaternion that's at the moment returned by the InterpolatorQuat. |
| 612 | 620 |
* |
| 613 |
* @param p Coordinates of the Point we are rotating around. |
|
| 614 |
* @param iq - Interpolator that's going to, at any given moment, return a quaternion.
|
|
| 615 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 621 |
* @param point Coordinates of the Point we are rotating around.
|
|
| 622 |
* @param iq Interpolator that's going to, at any given moment, return a quaternion.
|
|
| 623 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 616 | 624 |
*/ |
| 617 | 625 |
public long quaternion(Float3D point, InterpolatorQuat iq) |
| 618 | 626 |
{
|
| ... | ... | |
| 623 | 631 |
/** |
| 624 | 632 |
* Rotates the Object around a moving point by a quaternion that's at the moment returned by the InterpolatorQuat. |
| 625 | 633 |
* |
| 626 |
* @param i Interpolator that returns the current center of rotation. |
|
| 634 |
* @param i Interpolator that returns the current center of rotation.
|
|
| 627 | 635 |
* @param iq Interpolator that's going to, at any given moment, return a quaternion representing the current rotation. |
| 628 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 636 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 629 | 637 |
*/ |
| 630 | 638 |
public long quaternion(Interpolator3D i, InterpolatorQuat iq) |
| 631 | 639 |
{
|
| ... | ... | |
| 638 | 646 |
* Shears the Object. If the Interpolator is 1D, it will shear along the X-axis. 2D Interpolator adds |
| 639 | 647 |
* shearing along the Y-axis, 3D one along Z axis. |
| 640 | 648 |
* |
| 641 |
* @param p Center of shearing, i.e. the point which stays unmoved. |
|
| 642 |
* @param di 1- 2- or 3D Interpolator which, at any given point, returns the ordered 1-, 2- or 3-tuple
|
|
| 643 |
* of shear factors. |
|
| 644 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 649 |
* @param point Center of shearing, i.e. the point which stays unmoved.
|
|
| 650 |
* @param di 1- 2- or 3D Interpolator which, at any given point, returns the ordered 1-, 2-
|
|
| 651 |
* or 3-tuple of shear factors.
|
|
| 652 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 645 | 653 |
*/ |
| 646 | 654 |
public long shear(Float3D point, Interpolator di) |
| 647 | 655 |
{
|
| ... | ... | |
| 652 | 660 |
/** |
| 653 | 661 |
* Shears the Object in 3D. Order: first X shearing, then Y, then Z. |
| 654 | 662 |
* |
| 655 |
* @param p Center of shearing, i.e. the point which stays unmoved. |
|
| 656 |
* @param v ordered 3-tuple (x-degree, y-degree, z-degree) of shearing (tangent of the angle with
|
|
| 657 |
* which the X,Y and Z axis get slanted) |
|
| 658 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 663 |
* @param point Center of shearing, i.e. the point which stays unmoved.
|
|
| 664 |
* @param vector ordered 3-tuple (x-degree, y-degree, z-degree) of shearing (tangent of the angle with
|
|
| 665 |
* which the X,Y and Z axis get slanted)
|
|
| 666 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 659 | 667 |
*/ |
| 660 | 668 |
public long shear(Float3D point, Float3D vector) |
| 661 | 669 |
{
|
| ... | ... | |
| 676 | 684 |
* Creates macroblocks at and around point defined by the Interpolator2D and the Region. |
| 677 | 685 |
* Size of the macroblocks at any given time is returned by the Interpolator1D. |
| 678 | 686 |
* |
| 679 |
* @param a a 1-dimensional Interpolator which, at any given time, returns the size of the macroblocks.
|
|
| 680 |
* @param r The Region this Effect is limited to.
|
|
| 681 |
* Null here means 'apply the effect to the whole Bitmap'. |
|
| 682 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the |
|
| 683 |
* current center of the effect. |
|
| 684 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 687 |
* @param a 1-dimensional Interpolator which, at any given time, returns the size of the macroblocks.
|
|
| 688 |
* @param region Region this Effect is limited to.
|
|
| 689 |
* Null here means 'apply the effect to the whole Bitmap'.
|
|
| 690 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 691 |
* current center of the effect.
|
|
| 692 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 685 | 693 |
*/ |
| 686 | 694 |
public long macroblock(Interpolator1D a, Float4D region, Interpolator2D i) |
| 687 | 695 |
{
|
| ... | ... | |
| 695 | 703 |
* <p> |
| 696 | 704 |
* The difference between this and the previous method is that here the center of the Effect stays constant. |
| 697 | 705 |
* |
| 698 |
* @param a a 1-dimensional Interpolator which, at any given time, returns the size of the macroblocks.
|
|
| 699 |
* @param r The Region this Effect is limited to.
|
|
| 700 |
* Null here means 'apply the effect to the whole Bitmap'. |
|
| 701 |
* @param p Center of the Effect. |
|
| 702 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 706 |
* @param a 1-dimensional Interpolator which, at any given time, returns the size of the macroblocks.
|
|
| 707 |
* @param region Region this Effect is limited to.
|
|
| 708 |
* Null here means 'apply the effect to the whole Bitmap'.
|
|
| 709 |
* @param point Center of the Effect.
|
|
| 710 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 703 | 711 |
*/ |
| 704 | 712 |
public long macroblock(Interpolator1D a, Float4D region, Float2D point) |
| 705 | 713 |
{
|
| ... | ... | |
| 714 | 722 |
* they are of (pixels X pixels) size; after 'duration' milliseconds there are again none (i.e. their |
| 715 | 723 |
* size is 1X1, i.e. 1 pixel). |
| 716 | 724 |
* |
| 717 |
* @param pixels The maximum size, in pixels, of the Macroblocks we want to see.
|
|
| 718 |
* @param r The Region this Effect is limited to.
|
|
| 719 |
* Null here means 'apply the effect to the whole Bitmap'. |
|
| 720 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the |
|
| 721 |
* current center of the effect. |
|
| 725 |
* @param pixels Maximum size, in pixels, of the Macroblocks we want to see.
|
|
| 726 |
* @param region Region this Effect is limited to.
|
|
| 727 |
* Null here means 'apply the effect to the whole Bitmap'.
|
|
| 728 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 729 |
* current center of the effect.
|
|
| 722 | 730 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 723 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 724 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 731 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 732 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 725 | 733 |
*/ |
| 726 | 734 |
public long macroblock(int pixels, Float4D region, Interpolator2D i, int duration, float count) |
| 727 | 735 |
{
|
| ... | ... | |
| 744 | 752 |
* <p> |
| 745 | 753 |
* The difference between this and the previous method is that here the center of the Effect stays constant. |
| 746 | 754 |
* |
| 747 |
* @param pixels The maximum size, in pixels, of the Macroblocks we want to see.
|
|
| 748 |
* @param r The Region this Effect is limited to.
|
|
| 749 |
* Null here means 'apply the effect to the whole Bitmap'. |
|
| 750 |
* @param p Center of the Effect. |
|
| 755 |
* @param pixels Maximum size, in pixels, of the Macroblocks we want to see.
|
|
| 756 |
* @param region Region this Effect is limited to.
|
|
| 757 |
* Null here means 'apply the effect to the whole Bitmap'.
|
|
| 758 |
* @param point Center of the Effect.
|
|
| 751 | 759 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 752 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 753 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 760 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 761 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 754 | 762 |
*/ |
| 755 | 763 |
public long macroblock(int pixels, Float4D region, Float2D point, int duration, float count) |
| 756 | 764 |
{
|
| ... | ... | |
| 774 | 782 |
* The difference between this and the previous method is that here there is no masking Region; thus |
| 775 | 783 |
* there is also no center of the Effect. |
| 776 | 784 |
* |
| 777 |
* @param pixels The maximum size, in pixels, of the Macroblocks we want to see.
|
|
| 785 |
* @param pixels Maximum size, in pixels, of the Macroblocks we want to see.
|
|
| 778 | 786 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 779 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 780 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 787 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 788 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 781 | 789 |
*/ |
| 782 | 790 |
public long macroblock(int pixels, int duration, float count) |
| 783 | 791 |
{
|
| ... | ... | |
| 796 | 804 |
/** |
| 797 | 805 |
* Makes a certain sub-region of the Bitmap smoothly change all three of its RGB components. |
| 798 | 806 |
* |
| 799 |
* @param a a 1-dimensional Interpolator that returns the level of blend a given pixel will be mixed with
|
|
| 800 |
* the next parameter 'color': pixel = (1-level)*pixel + level*color |
|
| 801 |
* @param color The color to mix.
|
|
| 802 |
* @param r The Region this Effect is limited to.
|
|
| 803 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 804 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 805 |
* current center of the effect. |
|
| 806 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 807 |
* @param t 1-dimensional Interpolator that returns the level of blend a given pixel will be
|
|
| 808 |
* mixed with the next parameter 'color': pixel = (1-level)*pixel + level*color
|
|
| 809 |
* @param color Color to mix.
|
|
| 810 |
* @param region Region this Effect is limited to.
|
|
| 811 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 812 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing
|
|
| 813 |
* the current center of the effect.
|
|
| 814 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 807 | 815 |
*/ |
| 808 | 816 |
public long chroma(Interpolator1D t, Float3D color, Float4D region, Interpolator2D i) |
| 809 | 817 |
{
|
| ... | ... | |
| 816 | 824 |
* <p> |
| 817 | 825 |
* Here the center of the Effect stays constant. |
| 818 | 826 |
* |
| 819 |
* @param a a 1-dimensional Interpolator that returns the level of blend a given pixel will be mixed with
|
|
| 820 |
* the next parameter 'color': pixel = (1-level)*pixel + level*color |
|
| 821 |
* @param color The color to mix.
|
|
| 822 |
* @param r The Region this Effect is limited to.
|
|
| 823 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 824 |
* @param p Center of the Effect. |
|
| 825 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 827 |
* @param t 1-dimensional Interpolator that returns the level of blend a given pixel will be
|
|
| 828 |
* mixed with the next parameter 'color': pixel = (1-level)*pixel + level*color
|
|
| 829 |
* @param color Color to mix.
|
|
| 830 |
* @param region Region this Effect is limited to.
|
|
| 831 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 832 |
* @param point Center of the Effect.
|
|
| 833 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 826 | 834 |
*/ |
| 827 | 835 |
public long chroma(Interpolator1D t, Float3D color, Float4D region, Float2D point) |
| 828 | 836 |
{
|
| ... | ... | |
| 833 | 841 |
/** |
| 834 | 842 |
* Makes a certain sub-region of the Bitmap smoothly change all three of its RGB components. |
| 835 | 843 |
* |
| 836 |
* @param t the level of blend a given pixel will be mixed with the next parameter 'color':
|
|
| 837 |
* pixel = (1-t)*pixel + t*color |
|
| 838 |
* @param color The color to mix.
|
|
| 839 |
* @param reg The Region this Effect is limited to.
|
|
| 840 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 841 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the |
|
| 842 |
* current center of the effect. |
|
| 843 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 844 |
* @param t Level of blend a given pixel will be mixed with the next parameter 'color':
|
|
| 845 |
* pixel = (1-t)*pixel + t*color
|
|
| 846 |
* @param color Color to mix.
|
|
| 847 |
* @param region Region this Effect is limited to.
|
|
| 848 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 849 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 850 |
* current center of the effect.
|
|
| 851 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 844 | 852 |
*/ |
| 845 | 853 |
public long chroma(float t, Float3D color, Float4D region, Interpolator2D i) |
| 846 | 854 |
{
|
| 847 | 855 |
return mF.add(EffectNames.CHROMA, t, color, region, i); |
| 848 | 856 |
} |
| 849 | 857 |
|
| 850 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
|
| 858 |
///// //////////////////////////////////////////////////////////////////////////////////////////////
|
|
| 851 | 859 |
/** |
| 852 | 860 |
* Makes a certain sub-region of the Bitmap smoothly change all three of its RGB components. |
| 853 | 861 |
* <p> |
| 854 | 862 |
* Here the center of the Effect stays constant. |
| 855 | 863 |
* |
| 856 |
* @param t the level of blend a given pixel will be mixed with the next parameter 'color':
|
|
| 857 |
* pixel = (1-t)*pixel + t*color |
|
| 858 |
* @param color The color to mix.
|
|
| 859 |
* @param reg The Region this Effect is limited to. |
|
| 860 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 861 |
* @param p Center of the Effect. |
|
| 862 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 864 |
* @param t Level of blend a given pixel will be mixed with the next parameter 'color':
|
|
| 865 |
* pixel = (1-t)*pixel + t*color
|
|
| 866 |
* @param color Color to mix.
|
|
| 867 |
* @param region The Region this Effect is limited to.
|
|
| 868 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 869 |
* @param point Center of the Effect.
|
|
| 870 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 863 | 871 |
*/ |
| 864 | 872 |
public long chroma(float t, Float3D color, Float4D region, Float2D point) |
| 865 | 873 |
{
|
| ... | ... | |
| 872 | 880 |
* <p> |
| 873 | 881 |
* Here the Effect applies to the whole bitmap. |
| 874 | 882 |
* |
| 875 |
* @param t the level of blend a given pixel will be mixed with the next parameter 'color':
|
|
| 876 |
* pixel = (1-t)*pixel + t*color |
|
| 877 |
* @param color The color to mix.
|
|
| 878 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 883 |
* @param t Level of blend a given pixel will be mixed with the next parameter 'color':
|
|
| 884 |
* pixel = (1-t)*pixel + t*color
|
|
| 885 |
* @param color Color to mix.
|
|
| 886 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 879 | 887 |
*/ |
| 880 | 888 |
public long chroma(float t, Float3D color) |
| 881 | 889 |
{
|
| ... | ... | |
| 943 | 951 |
/** |
| 944 | 952 |
* Makes a certain sub-region of the Bitmap smoothly change its transparency level. |
| 945 | 953 |
* |
| 946 |
* @param a a 1-dimensional Interpolator that returns the level of transparency we want to have at any given
|
|
| 947 |
* moment. |
|
| 948 |
* @param r The Region this Effect is limited to.
|
|
| 949 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 950 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the |
|
| 951 |
* current center of the effect. |
|
| 952 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 954 |
* @param a 1-dimensional Interpolator that returns the level of transparency we want to have at any given
|
|
| 955 |
* moment.
|
|
| 956 |
* @param region Region this Effect is limited to.
|
|
| 957 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 958 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 959 |
* current center of the effect.
|
|
| 960 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 953 | 961 |
*/ |
| 954 | 962 |
public long alpha(Interpolator1D a, Float4D region, Interpolator2D i) |
| 955 | 963 |
{
|
| ... | ... | |
| 962 | 970 |
* <p> |
| 963 | 971 |
* Here the center of the Effect stays constant. |
| 964 | 972 |
* |
| 965 |
* @param a a 1-dimensional Interpolator that returns the level of transparency we want to have at any given
|
|
| 966 |
* moment. |
|
| 967 |
* @param r The Region this Effect is limited to.
|
|
| 968 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 969 |
* @param p Center of the Effect. |
|
| 970 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 973 |
* @param a 1-dimensional Interpolator that returns the level of transparency we want to have at any given
|
|
| 974 |
* moment.
|
|
| 975 |
* @param region Region this Effect is limited to.
|
|
| 976 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 977 |
* @param point Center of the Effect.
|
|
| 978 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 971 | 979 |
*/ |
| 972 | 980 |
public long alpha(Interpolator1D a, Float4D region, Float2D point) |
| 973 | 981 |
{
|
| ... | ... | |
| 978 | 986 |
/** |
| 979 | 987 |
* Makes a certain sub-region of the Bitmap smoothly change its transparency level. |
| 980 | 988 |
* |
| 981 |
* @param alpha Level of Alpha (0<=Alpha<=1) we want to interpolate to.
|
|
| 982 |
* @param r The Region this Effect is limited to.
|
|
| 983 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 984 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the |
|
| 985 |
* current center of the effect. |
|
| 989 |
* @param alpha Level of Alpha (between 0 and 1) we want to interpolate to.
|
|
| 990 |
* @param region Region this Effect is limited to.
|
|
| 991 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 992 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 993 |
* current center of the effect.
|
|
| 986 | 994 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 987 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 988 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 995 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 996 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 989 | 997 |
*/ |
| 990 | 998 |
public long alpha(float alpha, Float4D region, Interpolator2D i, int duration, float count) |
| 991 | 999 |
{
|
| ... | ... | |
| 1004 | 1012 |
* <p> |
| 1005 | 1013 |
* Here the center of the Effect stays constant. |
| 1006 | 1014 |
* |
| 1007 |
* @param alpha Level of Alpha (0<=Alpha<=1) we want to interpolate to.
|
|
| 1008 |
* @param r The Region this Effect is limited to.
|
|
| 1009 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1010 |
* @param p Center of the Effect. |
|
| 1015 |
* @param alpha Level of Alpha (between 0 and 1) we want to interpolate to.
|
|
| 1016 |
* @param region Region this Effect is limited to.
|
|
| 1017 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1018 |
* @param point Center of the Effect.
|
|
| 1011 | 1019 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 1012 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1013 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1020 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1021 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1014 | 1022 |
*/ |
| 1015 | 1023 |
public long alpha(float alpha, Float4D region, Float2D point, int duration, float count) |
| 1016 | 1024 |
{
|
| ... | ... | |
| 1029 | 1037 |
* <p> |
| 1030 | 1038 |
* Here the center of the Effect stays constant and the effect for now change in time. |
| 1031 | 1039 |
* |
| 1032 |
* @param alpha Level of Alpha (0<=Alpha<=1) we want to interpolate to.
|
|
| 1033 |
* @param r The Region this Effect is limited to.
|
|
| 1034 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1035 |
* @param p Center of the Effect. |
|
| 1036 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1040 |
* @param alpha Level of Alpha (between 0 and 1) we want to interpolate to.
|
|
| 1041 |
* @param region Region this Effect is limited to.
|
|
| 1042 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1043 |
* @param point Center of the Effect.
|
|
| 1044 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1037 | 1045 |
*/ |
| 1038 | 1046 |
public long alpha(float alpha, Float4D region, Float2D point) |
| 1039 | 1047 |
{
|
| ... | ... | |
| 1050 | 1058 |
/** |
| 1051 | 1059 |
* Makes the whole Bitmap change its transparency level. |
| 1052 | 1060 |
* |
| 1053 |
* @param alpha Level of Alpha (0<=Alpha<=1) we want to interpolate to.
|
|
| 1061 |
* @param alpha Level of Alpha (between 0 and 1) we want to interpolate to.
|
|
| 1054 | 1062 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 1055 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1056 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1063 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1064 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1057 | 1065 |
*/ |
| 1058 | 1066 |
public long alpha(float alpha, int duration, float count) |
| 1059 | 1067 |
{
|
| ... | ... | |
| 1145 | 1153 |
/** |
| 1146 | 1154 |
* Makes a certain sub-region of the Bitmap smoothly change its brightness level. |
| 1147 | 1155 |
* |
| 1148 |
* @param a a 1-dimensional Interpolator that returns the level of brightness we want to have at any given
|
|
| 1149 |
* moment. |
|
| 1150 |
* @param r The Region this Effect is limited to.
|
|
| 1151 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1152 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the |
|
| 1153 |
* current center of the effect. |
|
| 1154 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1156 |
* @param a 1-dimensional Interpolator that returns the level of brightness we want to have at any given
|
|
| 1157 |
* moment.
|
|
| 1158 |
* @param region Region this Effect is limited to.
|
|
| 1159 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1160 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 1161 |
* current center of the effect.
|
|
| 1162 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1155 | 1163 |
*/ |
| 1156 | 1164 |
public long brightness(Interpolator1D a, Float4D region, Interpolator2D i) |
| 1157 | 1165 |
{
|
| ... | ... | |
| 1164 | 1172 |
* <p> |
| 1165 | 1173 |
* Here the center of the Effect stays constant. |
| 1166 | 1174 |
* |
| 1167 |
* @param a a 1-dimensional Interpolator that returns the level of brightness we want to have at any given
|
|
| 1168 |
* moment. |
|
| 1169 |
* @param r The Region this Effect is limited to.
|
|
| 1170 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1171 |
* @param p Center of the Effect. |
|
| 1172 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1175 |
* @param a 1-dimensional Interpolator that returns the level of brightness we want to have at any given
|
|
| 1176 |
* moment.
|
|
| 1177 |
* @param region Region this Effect is limited to.
|
|
| 1178 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1179 |
* @param point Center of the Effect.
|
|
| 1180 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1173 | 1181 |
*/ |
| 1174 | 1182 |
public long brightness(Interpolator1D a, Float4D region, Float2D point) |
| 1175 | 1183 |
{
|
| ... | ... | |
| 1180 | 1188 |
/** |
| 1181 | 1189 |
* Makes a certain sub-region of the Bitmap smoothly change its brightness level. |
| 1182 | 1190 |
* |
| 1183 |
* @param brightness Level of Brightness (0<=brightness<=infinity) we want to interpolate to.
|
|
| 1184 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image', anything more than 1-
|
|
| 1185 |
* lighten it up. |
|
| 1186 |
* @param r The Region this Effect is limited to.
|
|
| 1187 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1188 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 1189 |
* current center of the effect. |
|
| 1190 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
|
| 1191 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1192 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1191 |
* @param brightness Level of Brightness (between 0 and infinity) we want to interpolate to.
|
|
| 1192 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image',
|
|
| 1193 |
* anything more than 1- lighten it up.
|
|
| 1194 |
* @param region Region this Effect is limited to.
|
|
| 1195 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1196 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D
|
|
| 1197 |
* representing the current center of the effect.
|
|
| 1198 |
* @param duration Time, in milliseconds, it takes to do one full interpolation.
|
|
| 1199 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1200 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1193 | 1201 |
*/ |
| 1194 | 1202 |
public long brightness(float brightness, Float4D region, Interpolator2D i, int duration, float count) |
| 1195 | 1203 |
{
|
| ... | ... | |
| 1208 | 1216 |
* <p> |
| 1209 | 1217 |
* Here the center of the Effect stays constant. |
| 1210 | 1218 |
* |
| 1211 |
* @param brightness Level of Brightness (0<=brightness<=infinity) we want to interpolate to.
|
|
| 1212 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image', anything more than 1-
|
|
| 1213 |
* lighten it up. |
|
| 1214 |
* @param r The Region this Effect is limited to.
|
|
| 1215 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1216 |
* @param p Center of the Effect. |
|
| 1217 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
|
| 1218 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1219 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1219 |
* @param brightness Level of Brightness (between 0 and infinity) we want to interpolate to.
|
|
| 1220 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image',
|
|
| 1221 |
* anything more than 1 - lighten it up.
|
|
| 1222 |
* @param region Region this Effect is limited to.
|
|
| 1223 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1224 |
* @param point Center of the Effect.
|
|
| 1225 |
* @param duration Time, in milliseconds, it takes to do one full interpolation.
|
|
| 1226 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1227 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1220 | 1228 |
*/ |
| 1221 | 1229 |
public long brightness(float brightness, Float4D region, Float2D point, int duration, float count) |
| 1222 | 1230 |
{
|
| ... | ... | |
| 1235 | 1243 |
* <p> |
| 1236 | 1244 |
* Here the center of the Effect stays constant and the effect for now change in time. |
| 1237 | 1245 |
* |
| 1238 |
* @param brightness Level of Brightness (0<=brightness<=infinity) we want to interpolate to.
|
|
| 1239 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image', anything more than 1-
|
|
| 1240 |
* lighten it up. |
|
| 1241 |
* @param r The Region this Effect is limited to.
|
|
| 1242 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1243 |
* @param p Center of the Effect. |
|
| 1244 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1246 |
* @param brightness Level of Brightness (between 0 and infinity) we want to interpolate to.
|
|
| 1247 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image',
|
|
| 1248 |
* anything more than 1 - lighten it up.
|
|
| 1249 |
* @param region Region this Effect is limited to.
|
|
| 1250 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1251 |
* @param point Center of the Effect.
|
|
| 1252 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1245 | 1253 |
*/ |
| 1246 | 1254 |
public long brightness(float brightness, Float4D region, Float2D point) |
| 1247 | 1255 |
{
|
| ... | ... | |
| 1260 | 1268 |
/** |
| 1261 | 1269 |
* Makes a certain sub-region of the Bitmap smoothly change its brightness level. |
| 1262 | 1270 |
* |
| 1263 |
* @param a a 1-dimensional Interpolator that returns the level of brightness we want to have at any given
|
|
| 1264 |
* moment. |
|
| 1265 |
* @param r The Region this Effect is limited to.
|
|
| 1266 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1267 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 1268 |
* current center of the effect. |
|
| 1269 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1271 |
* @param a 1-dimensional Interpolator that returns the level of brightness we want to have at
|
|
| 1272 |
* any given moment.
|
|
| 1273 |
* @param region Region this Effect is limited to.
|
|
| 1274 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1275 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D
|
|
| 1276 |
* representing the current center of the effect.
|
|
| 1277 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1270 | 1278 |
*/ |
| 1271 | 1279 |
public long smooth_brightness(Interpolator1D a, Float4D region, Interpolator2D i) |
| 1272 | 1280 |
{
|
| ... | ... | |
| 1279 | 1287 |
* <p> |
| 1280 | 1288 |
* Here the center of the Effect stays constant. |
| 1281 | 1289 |
* |
| 1282 |
* @param a a 1-dimensional Interpolator that returns the level of brightness we want to have at any given
|
|
| 1283 |
* moment. |
|
| 1284 |
* @param r The Region this Effect is limited to.
|
|
| 1285 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1286 |
* @param p Center of the Effect. |
|
| 1287 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1290 |
* @param a 1-dimensional Interpolator that returns the level of brightness we want to have at
|
|
| 1291 |
* any given moment.
|
|
| 1292 |
* @param region Region this Effect is limited to.
|
|
| 1293 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1294 |
* @param point Center of the Effect.
|
|
| 1295 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1288 | 1296 |
*/ |
| 1289 | 1297 |
public long smooth_brightness(Interpolator1D a, Float4D region, Float2D point) |
| 1290 | 1298 |
{
|
| ... | ... | |
| 1295 | 1303 |
/** |
| 1296 | 1304 |
* Makes a certain sub-region of the Bitmap smoothly change its brightness level. |
| 1297 | 1305 |
* |
| 1298 |
* @param brightness Level of Brightness (0<=brightness<=infinity) we want to interpolate to.
|
|
| 1299 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image', anything more than 1-
|
|
| 1300 |
* lighten it up. |
|
| 1301 |
* @param r The Region this Effect is limited to.
|
|
| 1302 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1303 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 1304 |
* current center of the effect. |
|
| 1305 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
|
| 1306 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1307 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1306 |
* @param brightness Level of Brightness (between 0 and infinity) we want to interpolate to.
|
|
| 1307 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image',
|
|
| 1308 |
* anything more than 1 - lighten it up.
|
|
| 1309 |
* @param region Region this Effect is limited to.
|
|
| 1310 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1311 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D
|
|
| 1312 |
* represention the current center of the effect.
|
|
| 1313 |
* @param duration Time, in milliseconds, it takes to do one full interpolation.
|
|
| 1314 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1315 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1308 | 1316 |
*/ |
| 1309 | 1317 |
public long smooth_brightness(float brightness, Float4D region, Interpolator2D i, int duration, float count) |
| 1310 | 1318 |
{
|
| ... | ... | |
| 1323 | 1331 |
* <p> |
| 1324 | 1332 |
* Here the center of the Effect stays constant. |
| 1325 | 1333 |
* |
| 1326 |
* @param brightness Level of Brightness (0<=brightness<=infinity) we want to interpolate to.
|
|
| 1327 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image', anything more than 1-
|
|
| 1328 |
* lighten it up. |
|
| 1329 |
* @param r The Region this Effect is limited to.
|
|
| 1330 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1331 |
* @param p Center of the Effect. |
|
| 1332 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
|
| 1333 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1334 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1334 |
* @param brightness Level of Brightness (between 0 and infinity) we want to interpolate to.
|
|
| 1335 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image',
|
|
| 1336 |
* anything more than 1 - lighten it up.
|
|
| 1337 |
* @param region Region this Effect is limited to.
|
|
| 1338 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1339 |
* @param point Center of the Effect.
|
|
| 1340 |
* @param duration Time, in milliseconds, it takes to do one full interpolation.
|
|
| 1341 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1342 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1335 | 1343 |
*/ |
| 1336 | 1344 |
public long smooth_brightness(float brightness, Float4D region, Float2D point, int duration, float count) |
| 1337 | 1345 |
{
|
| ... | ... | |
| 1350 | 1358 |
* <p> |
| 1351 | 1359 |
* Here the center of the Effect stays constant and the effect for now change in time. |
| 1352 | 1360 |
* |
| 1353 |
* @param brightness Level of Brightness (0<=brightness<=infinity) we want to interpolate to.
|
|
| 1354 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image', anything more than 1-
|
|
| 1355 |
* lighten it up. |
|
| 1356 |
* @param r The Region this Effect is limited to.
|
|
| 1357 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1358 |
* @param p Center of the Effect. |
|
| 1359 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1361 |
* @param brightness Level of Brightness (between 0 and infinity) we want to interpolate to.
|
|
| 1362 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image',
|
|
| 1363 |
* anything more than 1 - lighten it up.
|
|
| 1364 |
* @param region Region this Effect is limited to.
|
|
| 1365 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1366 |
* @param point Center of the Effect.
|
|
| 1367 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1360 | 1368 |
*/ |
| 1361 | 1369 |
public long smooth_brightness(float brightness, Float4D region, Float2D point) |
| 1362 | 1370 |
{
|
| ... | ... | |
| 1373 | 1381 |
/** |
| 1374 | 1382 |
* Makes the whole Bitmap change its brightness level. |
| 1375 | 1383 |
* |
| 1376 |
* @param brightness Level of Brightness (0<=brightness<=infinity) we want to interpolate to.
|
|
| 1377 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image', anything more than 1-
|
|
| 1378 |
* lighten it up. |
|
| 1379 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
|
| 1380 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1381 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1384 |
* @param brightness Level of Brightness (between 0 and infinity) we want to interpolate to.
|
|
| 1385 |
* 1 - level of brightness unchanged, anything less than 1 - 'darken the image',
|
|
| 1386 |
* anything more than 1- lighten it up.
|
|
| 1387 |
* @param duration Time, in milliseconds, it takes to do one full interpolation.
|
|
| 1388 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1389 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1382 | 1390 |
*/ |
| 1383 | 1391 |
public long smooth_brightness(float brightness, int duration, float count) |
| 1384 | 1392 |
{
|
| ... | ... | |
| 1397 | 1405 |
/** |
| 1398 | 1406 |
* Makes a certain sub-region of the Bitmap smoothly change its contrast level. |
| 1399 | 1407 |
* |
| 1400 |
* @param a a 1-dimensional Interpolator that returns the level of contrast we want to have at any given
|
|
| 1401 |
* moment. |
|
| 1402 |
* @param r The Region this Effect is limited to.
|
|
| 1403 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1404 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 1405 |
* current center of the effect. |
|
| 1406 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1408 |
* @param a 1-dimensional Interpolator that returns the level of contrast we want to have
|
|
| 1409 |
* at any given moment.
|
|
| 1410 |
* @param region Region this Effect is limited to.
|
|
| 1411 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1412 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D
|
|
| 1413 |
* representing the current center of the effect.
|
|
| 1414 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1407 | 1415 |
*/ |
| 1408 | 1416 |
public long contrast(Interpolator1D a, Float4D region, Interpolator2D i) |
| 1409 | 1417 |
{
|
| ... | ... | |
| 1416 | 1424 |
* <p> |
| 1417 | 1425 |
* Here the center of the Effect stays constant. |
| 1418 | 1426 |
* |
| 1419 |
* @param a a 1-dimensional Interpolator that returns the level of contrast we want to have at any given
|
|
| 1420 |
* moment. |
|
| 1421 |
* @param r The Region this Effect is limited to.
|
|
| 1422 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1423 |
* @param p Center of the Effect. |
|
| 1424 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1427 |
* @param a 1-dimensional Interpolator that returns the level of contrast we want to have
|
|
| 1428 |
* at any given moment.
|
|
| 1429 |
* @param region Region this Effect is limited to.
|
|
| 1430 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1431 |
* @param point Center of the Effect.
|
|
| 1432 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1425 | 1433 |
*/ |
| 1426 | 1434 |
public long contrast(Interpolator1D a, Float4D region, Float2D point) |
| 1427 | 1435 |
{
|
| ... | ... | |
| 1432 | 1440 |
/** |
| 1433 | 1441 |
* Makes a certain sub-region of the Bitmap smoothly change its contrast level. |
| 1434 | 1442 |
* |
| 1435 |
* @param contrast Level of contrast (0<=contrast<=infinity) we want to interpolate to.
|
|
| 1436 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast, anything more than 1-
|
|
| 1437 |
* increase the contrast. |
|
| 1438 |
* @param r The Region this Effect is limited to.
|
|
| 1439 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1440 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 1441 |
* current center of the effect. |
|
| 1443 |
* @param contrast Level of contrast (between 0 and infinity) we want to interpolate to.
|
|
| 1444 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast,
|
|
| 1445 |
* anything more than 1 - increase the contrast.
|
|
| 1446 |
* @param region Region this Effect is limited to.
|
|
| 1447 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1448 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D
|
|
| 1449 |
* represention the current center of the effect.
|
|
| 1442 | 1450 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 1443 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1444 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1451 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1452 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1445 | 1453 |
*/ |
| 1446 | 1454 |
public long contrast(float contrast, Float4D region, Interpolator2D i, int duration, float count) |
| 1447 | 1455 |
{
|
| ... | ... | |
| 1460 | 1468 |
* <p> |
| 1461 | 1469 |
* Here the center of the Effect stays constant. |
| 1462 | 1470 |
* |
| 1463 |
* @param contrast Level of contrast (0<=contrast<=infinity) we want to interpolate to.
|
|
| 1464 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast, anything more than 1-
|
|
| 1465 |
* increase the contrast. |
|
| 1466 |
* @param r The Region this Effect is limited to.
|
|
| 1467 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1468 |
* @param p Center of the Effect. |
|
| 1471 |
* @param contrast Level of contrast (between 0 and infinity) we want to interpolate to.
|
|
| 1472 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast,
|
|
| 1473 |
* anything more than 1 -increase the contrast.
|
|
| 1474 |
* @param region Region this Effect is limited to.
|
|
| 1475 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1476 |
* @param point Center of the Effect.
|
|
| 1469 | 1477 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 1470 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1471 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1478 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1479 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1472 | 1480 |
*/ |
| 1473 | 1481 |
public long contrast(float contrast, Float4D region, Float2D point, int duration, float count) |
| 1474 | 1482 |
{
|
| ... | ... | |
| 1487 | 1495 |
* <p> |
| 1488 | 1496 |
* Here the center of the Effect stays constant and the effect for now change in time. |
| 1489 | 1497 |
* |
| 1490 |
* @param contrast Level of contrast (0<=contrast<=infinity) we want to interpolate to.
|
|
| 1491 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast, anything more than 1-
|
|
| 1492 |
* increase the contrast. |
|
| 1493 |
* @param r The Region this Effect is limited to.
|
|
| 1494 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1495 |
* @param p Center of the Effect. |
|
| 1496 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1498 |
* @param contrast Level of contrast (between 0 and infinity) we want to interpolate to.
|
|
| 1499 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast,
|
|
| 1500 |
* anything more than 1 - increase the contrast.
|
|
| 1501 |
* @param region Region this Effect is limited to.
|
|
| 1502 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1503 |
* @param point Center of the Effect.
|
|
| 1504 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1497 | 1505 |
*/ |
| 1498 | 1506 |
public long contrast(float contrast, Float4D region, Float2D point) |
| 1499 | 1507 |
{
|
| ... | ... | |
| 1512 | 1520 |
/** |
| 1513 | 1521 |
* Makes a certain sub-region of the Bitmap smoothly change its contrast level. |
| 1514 | 1522 |
* |
| 1515 |
* @param a a 1-dimensional Interpolator that returns the level of contrast we want to have at any given
|
|
| 1516 |
* moment. |
|
| 1517 |
* @param r The Region this Effect is limited to.
|
|
| 1518 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1519 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 1520 |
* current center of the effect. |
|
| 1521 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1523 |
* @param a 1-dimensional Interpolator that returns the level of contrast we want to have
|
|
| 1524 |
* at any given moment.
|
|
| 1525 |
* @param region Region this Effect is limited to.
|
|
| 1526 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1527 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D
|
|
| 1528 |
* representing the current center of the effect.
|
|
| 1529 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1522 | 1530 |
*/ |
| 1523 | 1531 |
public long smooth_contrast(Interpolator1D a, Float4D region, Interpolator2D i) |
| 1524 | 1532 |
{
|
| ... | ... | |
| 1531 | 1539 |
* <p> |
| 1532 | 1540 |
* Here the center of the Effect stays constant. |
| 1533 | 1541 |
* |
| 1534 |
* @param a a 1-dimensional Interpolator that returns the level of contrast we want to have at any given
|
|
| 1535 |
* moment. |
|
| 1536 |
* @param r The Region this Effect is limited to.
|
|
| 1537 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1538 |
* @param p Center of the Effect. |
|
| 1539 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1542 |
* @param a 1-dimensional Interpolator that returns the level of contrast we want to have
|
|
| 1543 |
* at any given moment.
|
|
| 1544 |
* @param region Region this Effect is limited to.
|
|
| 1545 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1546 |
* @param point Center of the Effect.
|
|
| 1547 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1540 | 1548 |
*/ |
| 1541 | 1549 |
public long smooth_contrast(Interpolator1D a, Float4D region, Float2D point) |
| 1542 | 1550 |
{
|
| ... | ... | |
| 1547 | 1555 |
/** |
| 1548 | 1556 |
* Makes a certain sub-region of the Bitmap smoothly change its contrast level. |
| 1549 | 1557 |
* |
| 1550 |
* @param contrast Level of contrast (0<=contrast<=infinity) we want to interpolate to.
|
|
| 1551 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast, anything more than 1-
|
|
| 1552 |
* increase the contrast. |
|
| 1553 |
* @param r The Region this Effect is limited to.
|
|
| 1554 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1555 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 1556 |
* current center of the effect. |
|
| 1558 |
* @param contrast Level of contrast (between 0 and infinity) we want to interpolate to.
|
|
| 1559 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast,
|
|
| 1560 |
* anything more than 1 - increase the contrast.
|
|
| 1561 |
* @param region Region this Effect is limited to.
|
|
| 1562 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1563 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D
|
|
| 1564 |
* representing the current center of the effect.
|
|
| 1557 | 1565 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 1558 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1559 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1566 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1567 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1560 | 1568 |
*/ |
| 1561 | 1569 |
public long smooth_contrast(float contrast, Float4D region, Interpolator2D i, int duration, float count) |
| 1562 | 1570 |
{
|
| ... | ... | |
| 1575 | 1583 |
* <p> |
| 1576 | 1584 |
* Here the center of the Effect stays constant. |
| 1577 | 1585 |
* |
| 1578 |
* @param contrast Level of contrast (0<=contrast<=infinity) we want to interpolate to.
|
|
| 1579 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast, anything more than 1-
|
|
| 1580 |
* increase the contrast. |
|
| 1581 |
* @param r The Region this Effect is limited to.
|
|
| 1582 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1583 |
* @param p Center of the Effect. |
|
| 1586 |
* @param contrast Level of contrast (between 0 and infinity) we want to interpolate to.
|
|
| 1587 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast,
|
|
| 1588 |
* anything more than 1 - increase the contrast.
|
|
| 1589 |
* @param region Region this Effect is limited to.
|
|
| 1590 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1591 |
* @param point Center of the Effect.
|
|
| 1584 | 1592 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 1585 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1586 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1593 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1594 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1587 | 1595 |
*/ |
| 1588 | 1596 |
public long smooth_contrast(float contrast, Float4D region, Float2D point, int duration, float count) |
| 1589 | 1597 |
{
|
| ... | ... | |
| 1602 | 1610 |
* <p> |
| 1603 | 1611 |
* Here the center of the Effect stays constant and the effect for now change in time. |
| 1604 | 1612 |
* |
| 1605 |
* @param contrast Level of contrast (0<=contrast<=infinity) we want to interpolate to.
|
|
| 1606 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast, anything more than 1-
|
|
| 1607 |
* increase the contrast. |
|
| 1608 |
* @param r The Region this Effect is limited to.
|
|
| 1609 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1610 |
* @param p Center of the Effect. |
|
| 1611 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1613 |
* @param contrast Level of contrast (between 0 and infinity) we want to interpolate to.
|
|
| 1614 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast,
|
|
| 1615 |
* anything more than 1 - increase the contrast.
|
|
| 1616 |
* @param region Region this Effect is limited to.
|
|
| 1617 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1618 |
* @param point Center of the Effect.
|
|
| 1619 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1612 | 1620 |
*/ |
| 1613 | 1621 |
public long smooth_contrast(float contrast, Float4D region, Float2D point) |
| 1614 | 1622 |
{
|
| ... | ... | |
| 1625 | 1633 |
/** |
| 1626 | 1634 |
* Makes the whole Bitmap change its contrast level. |
| 1627 | 1635 |
* |
| 1628 |
* @param contrast Level of contrast (0<=contrast<=infinity) we want to interpolate to.
|
|
| 1629 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast, anything more than 1-
|
|
| 1630 |
* increase the contrast. |
|
| 1636 |
* @param contrast Level of contrast (between 0 and infinity) we want to interpolate to.
|
|
| 1637 |
* 1 - level of contrast unchanged, anything less than 1 - reduce contrast,
|
|
| 1638 |
* anything omre than 1 - increase the contrast.
|
|
| 1631 | 1639 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 1632 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1633 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1640 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1641 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1634 | 1642 |
*/ |
| 1635 | 1643 |
public long smooth_contrast(float contrast, int duration, float count) |
| 1636 | 1644 |
{
|
| ... | ... | |
| 1650 | 1658 |
/** |
| 1651 | 1659 |
* Makes a certain sub-region of the Bitmap smoothly change its saturation level. |
| 1652 | 1660 |
* |
| 1653 |
* @param a a 1-dimensional Interpolator that returns the level of saturation we want to have at any given
|
|
| 1654 |
* moment. |
|
| 1655 |
* @param r The Region this Effect is limited to.
|
|
| 1656 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1657 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 1658 |
* current center of the effect. |
|
| 1659 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1661 |
* @param a 1-dimensional Interpolator that returns the level of saturation we want to have
|
|
| 1662 |
* at any given moment.
|
|
| 1663 |
* @param region Region this Effect is limited to.
|
|
| 1664 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1665 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D
|
|
| 1666 |
* representing the current center of the effect.
|
|
| 1667 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1660 | 1668 |
*/ |
| 1661 | 1669 |
public long saturation(Interpolator1D a, Float4D region, Interpolator2D i) |
| 1662 | 1670 |
{
|
| ... | ... | |
| 1669 | 1677 |
* <p> |
| 1670 | 1678 |
* Here the center of the Effect stays constant. |
| 1671 | 1679 |
* |
| 1672 |
* @param a a 1-dimensional Interpolator that returns the level of saturation we want to have at any given
|
|
| 1673 |
* moment. |
|
| 1674 |
* @param r The Region this Effect is limited to.
|
|
| 1675 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1676 |
* @param p Center of the Effect. |
|
| 1677 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1680 |
* @param a 1-dimensional Interpolator that returns the level of saturation we want to have
|
|
| 1681 |
* at any given moment.
|
|
| 1682 |
* @param region Region this Effect is limited to.
|
|
| 1683 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1684 |
* @param point Center of the Effect.
|
|
| 1685 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1678 | 1686 |
*/ |
| 1679 | 1687 |
public long saturation(Interpolator1D a, Float4D region, Float2D point) |
| 1680 | 1688 |
{
|
| ... | ... | |
| 1685 | 1693 |
/** |
| 1686 | 1694 |
* Makes a certain sub-region of the Bitmap smoothly change its saturation level. |
| 1687 | 1695 |
* |
| 1688 |
* @param saturation Level of saturation (0<=saturation<=infinity) we want to interpolate to.
|
|
| 1689 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation, anything more than 1-
|
|
| 1690 |
* increase the saturation. |
|
| 1691 |
* @param r The Region this Effect is limited to.
|
|
| 1692 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1693 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 1694 |
* current center of the effect. |
|
| 1695 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
|
| 1696 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1697 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1696 |
* @param saturation Level of saturation (between 0 and infinity) we want to interpolate to.
|
|
| 1697 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation,
|
|
| 1698 |
* anything more than 1 - increase the saturation.
|
|
| 1699 |
* @param region Region this Effect is limited to.
|
|
| 1700 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1701 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D
|
|
| 1702 |
* representing the current center of the effect.
|
|
| 1703 |
* @param duration Time, in milliseconds, it takes to do one full interpolation.
|
|
| 1704 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1705 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1698 | 1706 |
*/ |
| 1699 | 1707 |
public long saturation(float saturation, Float4D region, Interpolator2D i, int duration, float count) |
| 1700 | 1708 |
{
|
| ... | ... | |
| 1713 | 1721 |
* <p> |
| 1714 | 1722 |
* Here the center of the Effect stays constant. |
| 1715 | 1723 |
* |
| 1716 |
* @param saturation Level of saturation (0<=saturation<=infinity) we want to interpolate to.
|
|
| 1717 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation, anything more than 1-
|
|
| 1718 |
* increase the saturation. |
|
| 1719 |
* @param r The Region this Effect is limited to.
|
|
| 1720 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1721 |
* @param p Center of the Effect. |
|
| 1722 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
|
| 1723 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1724 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1724 |
* @param saturation Level of saturation (between 0 and infinity) we want to interpolate to.
|
|
| 1725 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation,
|
|
| 1726 |
* anything more than 1 - increase the saturation.
|
|
| 1727 |
* @param region Region this Effect is limited to.
|
|
| 1728 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1729 |
* @param point Center of the Effect.
|
|
| 1730 |
* @param duration Time, in milliseconds, it takes to do one full interpolation.
|
|
| 1731 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1732 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1725 | 1733 |
*/ |
| 1726 | 1734 |
public long saturation(float saturation, Float4D region, Float2D point, int duration, float count) |
| 1727 | 1735 |
{
|
| ... | ... | |
| 1740 | 1748 |
* <p> |
| 1741 | 1749 |
* Here the center of the Effect stays constant and the effect for now change in time. |
| 1742 | 1750 |
* |
| 1743 |
* @param saturation Level of saturation (0<=saturation<=infinity) we want to interpolate to.
|
|
| 1744 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation, anything more than 1-
|
|
| 1745 |
* increase the saturation. |
|
| 1746 |
* @param r The Region this Effect is limited to.
|
|
| 1747 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1748 |
* @param p Center of the Effect. |
|
| 1749 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1751 |
* @param saturation Level of saturation (between 0 and infinity) we want to interpolate to.
|
|
| 1752 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation,
|
|
| 1753 |
* anything more than 1- increase the saturation.
|
|
| 1754 |
* @param region Region this Effect is limited to.
|
|
| 1755 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1756 |
* @param point Center of the Effect.
|
|
| 1757 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1750 | 1758 |
*/ |
| 1751 | 1759 |
public long saturation(float saturation, Float4D region, Float2D point) |
| 1752 | 1760 |
{
|
| ... | ... | |
| 1765 | 1773 |
/** |
| 1766 | 1774 |
* Makes a certain sub-region of the Bitmap smoothly change its saturation level. |
| 1767 | 1775 |
* |
| 1768 |
* @param a a 1-dimensional Interpolator that returns the level of saturation we want to have at any given
|
|
| 1769 |
* moment. |
|
| 1770 |
* @param r The Region this Effect is limited to.
|
|
| 1771 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1772 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 1773 |
* current center of the effect. |
|
| 1774 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1776 |
* @param a 1-dimensional Interpolator that returns the level of saturation we want to have
|
|
| 1777 |
* at any given moment.
|
|
| 1778 |
* @param region Region this Effect is limited to.
|
|
| 1779 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1780 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D
|
|
| 1781 |
* representing the current center of the effect.
|
|
| 1782 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1775 | 1783 |
*/ |
| 1776 | 1784 |
public long smooth_saturation(Interpolator1D a, Float4D region, Interpolator2D i) |
| 1777 | 1785 |
{
|
| ... | ... | |
| 1784 | 1792 |
* <p> |
| 1785 | 1793 |
* Here the center of the Effect stays constant. |
| 1786 | 1794 |
* |
| 1787 |
* @param a a 1-dimensional Interpolator that returns the level of saturation we want to have at any given
|
|
| 1788 |
* moment. |
|
| 1789 |
* @param r The Region this Effect is limited to.
|
|
| 1790 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1791 |
* @param p Center of the Effect. |
|
| 1792 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1795 |
* @param a 1-dimensional Interpolator that returns the level of saturation we want to have
|
|
| 1796 |
* at any given moment.
|
|
| 1797 |
* @param region Region this Effect is limited to.
|
|
| 1798 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1799 |
* @param point Center of the Effect.
|
|
| 1800 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1793 | 1801 |
*/ |
| 1794 | 1802 |
public long smooth_saturation(Interpolator1D a, Float4D region, Float2D point) |
| 1795 | 1803 |
{
|
| ... | ... | |
| 1800 | 1808 |
/** |
| 1801 | 1809 |
* Makes a certain sub-region of the Bitmap smoothly change its saturation level. |
| 1802 | 1810 |
* |
| 1803 |
* @param saturation Level of saturation (0<=saturation<=infinity) we want to interpolate to.
|
|
| 1804 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation, anything more than 1-
|
|
| 1805 |
* increase the saturation. |
|
| 1806 |
* @param r The Region this Effect is limited to.
|
|
| 1807 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1808 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D representing the
|
|
| 1809 |
* current center of the effect. |
|
| 1810 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
|
| 1811 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1812 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1811 |
* @param saturation Level of saturation (between 0 and infinity) we want to interpolate to.
|
|
| 1812 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation,
|
|
| 1813 |
* anything more than 1 -increase the saturation.
|
|
| 1814 |
* @param region Region this Effect is limited to.
|
|
| 1815 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1816 |
* @param i 2-dimensional Interpolator which, at any given time, returns a Float2D
|
|
| 1817 |
* representing the current center of the effect.
|
|
| 1818 |
* @param duration Time, in milliseconds, it takes to do one full interpolation.
|
|
| 1819 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1820 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1813 | 1821 |
*/ |
| 1814 | 1822 |
public long smooth_saturation(float saturation, Float4D region, Interpolator2D i, int duration, float count) |
| 1815 | 1823 |
{
|
| ... | ... | |
| 1828 | 1836 |
* <p> |
| 1829 | 1837 |
* Here the center of the Effect stays constant. |
| 1830 | 1838 |
* |
| 1831 |
* @param saturation Level of saturation (0<=saturation<=infinity) we want to interpolate to.
|
|
| 1832 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation, anything more than 1-
|
|
| 1833 |
* increase the saturation. |
|
| 1834 |
* @param r The Region this Effect is limited to.
|
|
| 1835 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1836 |
* @param p Center of the Effect. |
|
| 1837 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
|
| 1838 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1839 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1839 |
* @param saturation Level of saturation (between 0 and infinity) we want to interpolate to.
|
|
| 1840 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation,
|
|
| 1841 |
* anything more than 1 - increase the saturation.
|
|
| 1842 |
* @param region Region this Effect is limited to.
|
|
| 1843 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1844 |
* @param point Center of the Effect.
|
|
| 1845 |
* @param duration Time, in milliseconds, it takes to do one full interpolation.
|
|
| 1846 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1847 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1840 | 1848 |
*/ |
| 1841 | 1849 |
public long smooth_saturation(float saturation, Float4D region, Float2D point, int duration, float count) |
| 1842 | 1850 |
{
|
| ... | ... | |
| 1855 | 1863 |
* <p> |
| 1856 | 1864 |
* Here the center of the Effect stays constant and the effect for now change in time. |
| 1857 | 1865 |
* |
| 1858 |
* @param saturation Level of saturation (0<=saturation<=infinity) we want to interpolate to.
|
|
| 1859 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation, anything more than 1-
|
|
| 1860 |
* increase the saturation. |
|
| 1861 |
* @param r The Region this Effect is limited to.
|
|
| 1862 |
* Null here means 'apply the Effect to the whole Bitmap'. |
|
| 1863 |
* @param p Center of the Effect. |
|
| 1864 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1866 |
* @param saturation Level of saturation (between 0 and infinity) we want to interpolate to.
|
|
| 1867 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation,
|
|
| 1868 |
* anything more than 1 - increase the saturation.
|
|
| 1869 |
* @param region Region this Effect is limited to.
|
|
| 1870 |
* Null here means 'apply the Effect to the whole Bitmap'.
|
|
| 1871 |
* @param point Center of the Effect.
|
|
| 1872 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1865 | 1873 |
*/ |
| 1866 | 1874 |
public long smooth_saturation(float saturation, Float4D region, Float2D point) |
| 1867 | 1875 |
{
|
| ... | ... | |
| 1878 | 1886 |
/** |
| 1879 | 1887 |
* Makes the whole Bitmap change its saturation level. |
| 1880 | 1888 |
* |
| 1881 |
* @param saturation Level of saturation (0<=saturation<=infinity) we want to interpolate to.
|
|
| 1882 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation, anything more than 1-
|
|
| 1883 |
* increase the saturation. |
|
| 1884 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
|
| 1885 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1886 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1889 |
* @param saturation Level of saturation (between 0 and infinity) we want to interpolate to.
|
|
| 1890 |
* 1 - level of saturation unchanged, anything less than 1 - reduce saturation,
|
|
| 1891 |
* anything more than 1 - increase the saturation.
|
|
| 1892 |
* @param duration Time, in milliseconds, it takes to do one full interpolation.
|
|
| 1893 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1894 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1887 | 1895 |
*/ |
| 1888 | 1896 |
public long smooth_saturation(float saturation, int duration, float count) |
| 1889 | 1897 |
{
|
| ... | ... | |
| 1903 | 1911 |
/** |
| 1904 | 1912 |
* Distort a (possibly changing in time) part of the Bitmap by a (possibly changing in time) vector of force. |
| 1905 | 1913 |
* |
| 1906 |
* @param i A 2- or 3-dimensional Interpolator that returns a 2- or 3-dimensional Point which represents
|
|
| 1907 |
* the vector the Center of the Effect is currently being dragged with. |
|
| 1908 |
* @param r Region that masks the effect of the Distortion. |
|
| 1909 |
* @param p A 2-dimensional Interpolator that, at any given time, returns a Point2D representing
|
|
| 1910 |
* the Center of the Effect. |
|
| 1911 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1914 |
* @param i 2- or 3-dimensional Interpolator that returns a 2- or 3-dimensional Point which
|
|
| 1915 |
* represents the vector the Center of the Effect is currently being dragged with.
|
|
| 1916 |
* @param region Region that masks the effect of the Distortion.
|
|
| 1917 |
* @param p 2-dimensional Interpolator that, at any given time, returns a Point2D representing
|
|
| 1918 |
* the Center of the Effect.
|
|
| 1919 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1912 | 1920 |
*/ |
| 1913 | 1921 |
public long distort(Interpolator i, Float4D region, Interpolator2D p) |
| 1914 | 1922 |
{
|
| ... | ... | |
| 1921 | 1929 |
* <p> |
| 1922 | 1930 |
* Difference between this and the previous method is that here the center of the Effect stays constant. |
| 1923 | 1931 |
* |
| 1924 |
* @param i A 2- or 3-dimensional Interpolator that returns a 2- or 3-dimensional Point which represents
|
|
| 1925 |
* the vector the Center of the Effect is currently being dragged with. |
|
| 1926 |
* @param r Region that masks the effect of the Distortion. |
|
| 1927 |
* @param p Center of the Effect. |
|
| 1928 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1932 |
* @param i 2- or 3-dimensional Interpolator that returns a 2- or 3-dimensional Point which
|
|
| 1933 |
* represents the vector the Center of the Effect is currently being dragged with.
|
|
| 1934 |
* @param region Region that masks the effect of the Distortion.
|
|
| 1935 |
* @param point Center of the Effect.
|
|
| 1936 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1929 | 1937 |
*/ |
| 1930 | 1938 |
public long distort(Interpolator i, Float4D region, Float2D point) |
| 1931 | 1939 |
{
|
| ... | ... | |
| 1936 | 1944 |
/** |
| 1937 | 1945 |
* Distort the whole Bitmap by a (possibly changing in time) vector of force. |
| 1938 | 1946 |
* |
| 1939 |
* @param i A 2- or 3-dimensional Interpolator that returns a 2- or 3-dimensional Point which represents
|
|
| 1940 |
* the vector the Center of the Effect is currently being dragged with. |
|
| 1941 |
* @param p Center of the Effect. |
|
| 1942 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1947 |
* @param i 2- or 3-dimensional Interpolator that returns a 2- or 3-dimensional Point which
|
|
| 1948 |
* represents the vector the Center of the Effect is currently being dragged with.
|
|
| 1949 |
* @param point Center of the Effect.
|
|
| 1950 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1943 | 1951 |
*/ |
| 1944 | 1952 |
public long distort(Interpolator i, Float2D point) |
| 1945 | 1953 |
{
|
| ... | ... | |
| 1950 | 1958 |
/** |
| 1951 | 1959 |
* Distort part of the Bitmap by a vector of force that changes from (0,0,0) to v. |
| 1952 | 1960 |
* |
| 1953 |
* @param v The maximum vector of force.
|
|
| 1954 |
* @param r Region that masks the effect of the Distortion. |
|
| 1955 |
* @param p Center of the Effect. |
|
| 1961 |
* @param vector Maximum vector of force.
|
|
| 1962 |
* @param region Region that masks the effect of the Distortion.
|
|
| 1963 |
* @param point Center of the Effect.
|
|
| 1956 | 1964 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 1957 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1958 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1965 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1966 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1959 | 1967 |
*/ |
| 1960 | 1968 |
public long distort(Float3D vector, Float4D region, Float2D point, int duration, float count) |
| 1961 | 1969 |
{
|
| ... | ... | |
| 1972 | 1980 |
/** |
| 1973 | 1981 |
* Distort the whole Bitmap by a vector of force that changes from (0,0,0) to v. |
| 1974 | 1982 |
* |
| 1975 |
* @param v The maximum vector of force.
|
|
| 1976 |
* @param p Center of the Effect. |
|
| 1983 |
* @param vector Maximum vector of force.
|
|
| 1984 |
* @param point Center of the Effect.
|
|
| 1977 | 1985 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 1978 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1979 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 1986 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 1987 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 1980 | 1988 |
*/ |
| 1981 | 1989 |
public long distort(Float3D vector, Float2D point, int duration, float count) |
| 1982 | 1990 |
{
|
| ... | ... | |
| 1996 | 2004 |
* Difference between this and the previous method is that here the vector of force will get interpolated |
| 1997 | 2005 |
* to the maximum v and the effect will end. We are thus limited to count=0.5. |
| 1998 | 2006 |
* |
| 1999 |
* @param v The maximum, final vector of force.
|
|
| 2000 |
* @param p Center of the Effect. |
|
| 2007 |
* @param vector Maximum, final vector of force.
|
|
| 2008 |
* @param point Center of the Effect.
|
|
| 2001 | 2009 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 2002 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 2010 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 2003 | 2011 |
*/ |
| 2004 | 2012 |
public long distort(Float3D vector, Float2D point, int duration) |
| 2005 | 2013 |
{
|
| ... | ... | |
| 2018 | 2026 |
* <p> |
| 2019 | 2027 |
* Here we apply a constant vector of force. |
| 2020 | 2028 |
* |
| 2021 |
* @param v The vector of force.
|
|
| 2022 |
* @param p Center of the Effect. |
|
| 2023 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 2029 |
* @param vector Vector of force.
|
|
| 2030 |
* @param point Center of the Effect.
|
|
| 2031 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 2024 | 2032 |
*/ |
| 2025 | 2033 |
public long distort(Float3D vector, Float2D point ) |
| 2026 | 2034 |
{
|
| ... | ... | |
| 2040 | 2048 |
* Deform the shape of the whole Bitmap with a (possibly changing in time) vector of force applied to |
| 2041 | 2049 |
* a (possibly changing in time) point on the Bitmap. |
| 2042 | 2050 |
* |
| 2043 |
* @param i A 2-dimensional Interpolator that, at any given time, returns a Point2D representing
|
|
| 2044 |
* vector of force that deforms the shapre of the whole Bitmap.
|
|
| 2045 |
* @param p A 2-dimensional Interpolator that, at any given time, returns a Point2D representing
|
|
| 2046 |
* the Center of the Effect. |
|
| 2047 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 2051 |
* @param i Interpolator that, at any given time, returns a Point2D representing vector of
|
|
| 2052 |
* force that deforms the shapre of the whole Bitmap.
|
|
| 2053 |
* @param point 2-dimensional Interpolator that, at any given time, returns a Point2D representing
|
|
| 2054 |
* the Center of the Effect.
|
|
| 2055 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 2048 | 2056 |
*/ |
| 2049 | 2057 |
public long deform(Interpolator i, Interpolator2D point) |
| 2050 | 2058 |
{
|
| ... | ... | |
| 2056 | 2064 |
* Deform the shape of the whole Bitmap with a (possibly changing in time) vector of force applied to |
| 2057 | 2065 |
* a constant point on the Bitmap. |
| 2058 | 2066 |
* |
| 2059 |
* @param i A 2-dimensional Interpolator that, at any given time, returns a Point2D representing
|
|
| 2060 |
* vector of force that deforms the shapre of the whole Bitmap. |
|
| 2061 |
* @param p Center of the Effect. |
|
| 2062 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 2067 |
* @param i Interpolator that, at any given time, returns a Point2D representing
|
|
| 2068 |
* vector of force that deforms the shapre of the whole Bitmap.
|
|
| 2069 |
* @param point Center of the Effect.
|
|
| 2070 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 2063 | 2071 |
*/ |
| 2064 | 2072 |
public long deform(Interpolator i, Float2D point) |
| 2065 | 2073 |
{
|
| ... | ... | |
| 2071 | 2079 |
* Deform the shape of the whole Bitmap with a vector of force smoothly changing from (0,0,0) to v |
| 2072 | 2080 |
* applied to a constant point on the Bitmap. |
| 2073 | 2081 |
* |
| 2074 |
* @param v Vector of force. |
|
| 2075 |
* @param p Center of the Effect. |
|
| 2082 |
* @param vector Vector of force.
|
|
| 2083 |
* @param point Center of the Effect.
|
|
| 2076 | 2084 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 2077 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 2078 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 2085 |
* @param count Controls how many interpolations we want to do. See {@link Interpolator#setCount(float)}
|
|
| 2086 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 2079 | 2087 |
*/ |
| 2080 | 2088 |
public long deform(Float3D vector, Float2D point, int duration, float count) |
| 2081 | 2089 |
{
|
| ... | ... | |
| 2095 | 2103 |
* <p> |
| 2096 | 2104 |
* Identical to calling the previous method with count=0.5. |
| 2097 | 2105 |
* |
| 2098 |
* @param v Final vector of force. |
|
| 2099 |
* @param p Center of the Effect. |
|
| 2106 |
* @param vector Final vector of force.
|
|
| 2107 |
* @param point Center of the Effect.
|
|
| 2100 | 2108 |
* @param duration Time, in milliseconds, it takes to do one full interpolation. |
| 2101 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 2109 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 2102 | 2110 |
*/ |
| 2103 | 2111 |
public long deform(Float3D vector, Float2D point, int duration) |
| 2104 | 2112 |
{
|
| ... | ... | |
| 2116 | 2124 |
* Deform the shape of the whole Bitmap with a constant vector of force applied to a constant |
| 2117 | 2125 |
* point on the Bitmap. |
| 2118 | 2126 |
* |
| 2119 |
* @param v Vector of force. |
|
| 2120 |
* @param p Center of the Effect. |
|
| 2121 |
* @return ID of the effect added, or -1 if we failed to add one. |
|
| 2127 |
* @param vector Vector of force.
|
|
| 2128 |
* @param point Center of the Effect.
|
|
| 2129 |
* @return ID of the effect added, or -1 if we failed to add one.
|
|
| 2122 | 2130 |
*/ |
| 2123 | 2131 |
public long deform(Float3D vector, Float2D point ) |
| 2124 | 2132 |
{
|
| ... | ... | |
| 2138 | 2146 |
* Pull all points around the center of the effect towards the center (if degree>=1) or push them |
| 2139 | 2147 |
* away from the center (degree<=1) |
Also available in: Unified diff
Fix javadoc errors