Module gwy
[hide private]
[frames] | no frames]

Source Code for Module gwy

    1  # This is dummy GENERATED file used for generation of documentation 
2 -class Axis:
3 - def __init__( orientation ):
4 """ 5 Creates a new axis. 6 7 8 @return: New axis as a B{C{GtkWidget}}. 9 10 """ 11 return None
12 - def set_logarithmic( is_logarithmic ):
13 """ 14 Sets logarithmic mode. 15 16 @param is_logarithmic: logarithmic mode I{(bool)} 17 @return: 18 """ 19 return None
20 - def set_visible( is_visible ):
21 """ 22 Sets the visibility of an axis. 23 24 @param is_visible: visibility I{(bool)} 25 @return: 26 """ 27 return None
28 - def is_visible( ):
29 """ 30 Determines whether axis is set to be visible. 31 32 Return: B{C{True}} if B{C{axis}} is set to be visible. 33 34 @return: 35 """ 36 return None
37 - def is_logarithmic( ):
38 """ 39 Determines whether axis is set to be locarithmic. 40 41 42 @return: B{C{True}} if B{C{axis}} is logarithmic. 43 44 """ 45 return None
46 - def get_orientation( ):
47 """ 48 Gets the orientation of an axis. 49 50 51 @return: The orientation. 52 53 """ 54 return None
55 - def set_auto( is_auto ):
56 """ 57 Enables or disables automatic axis adjustmet. 58 59 @param is_auto: B{C{True}} to enable automatic tick size and distribution adjustment, 60 B{C{False}} to disable it. I{(bool)} 61 @return: 62 """ 63 return None
64 - def request_range( min , max ):
65 """ 66 Sets the requisition of axis boundaries. 67 68 The axis will adjust the boundaries to satisfy requisition but still have 69 reasonable tick values and spacing. Use L{Axis.get_range}() to obtain the 70 boundaries the axis actually decided to use. 71 72 @param min: Minimum requisition (min boundary value). I{(float)} 73 @param max: Maximum requisition (max boundary value). I{(float)} 74 @return: 75 """ 76 return None
77 - def get_range( min , max ):
78 """ 79 Gets the actual boundaries of an axis. 80 81 @param min: Location to store actual axis minimum, or B{C{NULL}}. I{(float)} 82 @param max: Location to store actual axis maximum, or B{C{NULL}}. I{(float)} 83 @return: 84 """ 85 return None
86 - def get_requested_range( min , max ):
87 """ 88 Gets the requested boundaries of an axis. 89 90 @param min: Location to store requested axis minimum, or B{C{NULL}}. I{(float)} 91 @param max: Location to store requested axis maximum, or B{C{NULL}}. I{(float)} 92 @return: 93 """ 94 return None
95 - def get_magnification( ):
96 """ 97 98 @return: Magnification value of the axis 99 100 """ 101 return None
103 """ 104 Gets the magnification string of an axis. 105 106 107 @return: Magnification string of the axis, owned by the axis. 108 109 """ 110 return None
111 - def set_label( label ):
112 """ 113 Sets the label text of an axis. 114 115 @param label: The new label text (it can be B{C{NULL}} for an empty label). I{(string)} 116 @return: 117 """ 118 return None
119 - def get_label( ):
120 """ 121 Gets the label of an axis. 122 123 124 @return: Axis label as a string owned by B{C{axis}}. 125 126 """ 127 return None
128 - def set_si_unit( unit ):
129 """ 130 Sets the axis unit. This will be added automatically 131 to the label. B{C{unit}} is duplicated. 132 133 @param unit: axis unit I{(L{SIUnit})} 134 @return: 135 """ 136 return None
137 - def enable_label_edit( enable ):
138 """ 139 Enables/disables user to change axis label by clicking on axis widget. 140 141 @param enable: enable/disable user to change axis label I{(bool)} 142 @return: 143 """ 144 return None
145 - def draw_on_drawable( drawable , gc , xmin , ymin , width , height ):
146 """ 147 Draws the x and y-axis on a drawable 148 149 @param drawable: Drawable to draw on. I{(GdkDrawable*)} 150 @param gc: Graphics context. 151 It is modified by this function unpredictably. I{(GdkGC*)} 152 @param xmin: The minimum x-axis value. I{(int)} 153 @param ymin: The minimum y-axis value. I{(int)} 154 @param width: The width of the x-axis. I{(int)} 155 @param height: The height of the y-axis. I{(int)} 156 @return: 157 """ 158 return None
159 - def UNIMPLEMENTED_export_vector( xmin , ymin , width , height , fontsize ):
160 """ 161 162 @param xmin: I{(int)} 163 @param ymin: I{(int)} 164 @param width: width of the x-axis I{(int)} 165 @param height: hieght of the y-axis I{(int)} 166 @param fontsize: I{(int)} 167 @return: 168 """ 169 return None
170 - def get_major_ticks( nticks ):
171 """ 172 Gets the positions of major ticks of an axis. 173 174 175 @param nticks: Location to store the number of returned ticks. I{(int)} 176 @return: The positions of axis major ticks (as real values, not pixels). 177 The returned array is owned by the axis. 178 179 """ 180 return None
181 -class Brick:
182 - def __init__( xres , yres , zres , xreal , yreal , zreal , nullme ):
183 """ 184 Creates a new data brick. 185 186 Since: 2.31 187 188 @param yres: Y resolution, i.e., the number of samples in y direction I{(int)} 189 @param zres: Z resolution, i.e., the number of samples in z direction I{(int)} 190 @param xreal: Real physical dimension in x direction. I{(float)} 191 @param yreal: Real physical dimension in y direction. I{(float)} 192 @param zreal: Real physical dimension in z direction. I{(float)} 193 @param nullme: Whether the data brick should be initialized to zeroes. If B{C{False}}, 194 the data will not be initialized. I{(bool)} 195 @return: A newly created data brick. 196 197 198 """ 199 return None
200 - def new_alike( nullme ):
201 """ 202 Creates a new data brick similar to an existing one. 203 204 Use L{Brick.duplicate}() if you want to copy a data brick including 205 data. 206 207 Since: 2.31 208 209 @param nullme: Whether the data brick should be initialized to zeroes. If B{C{False}}, 210 the data will not be initialized. I{(bool)} 211 @return: A newly created data brick. 212 213 214 """ 215 return None
216 - def new_part( xpos , ypos , zpos , xres , yres , zres , keep_offsets ):
217 """ 218 Creates a new data brick as a part of existing one. 219 220 Use L{Brick.duplicate}() if you want to copy a whole data brick. 221 222 Since: 2.32 223 224 @param xpos: x position where to start from I{(int)} 225 @param ypos: y position where to start from I{(int)} 226 @param zpos: z position where to start from I{(int)} 227 @param xres: x resolution (width) to be extracted I{(int)} 228 @param yres: y resolution (height) to be extracted I{(int)} 229 @param zres: z resolution (depth) to be extracted I{(int)} 230 @param keep_offsets: keep offsets of data during extraction I{(bool)} 231 @return: A newly created data brick. 232 233 234 """ 235 return None
236 - def data_changed( ):
237 """ 238 Emits signal "data_changed" on a data brick. 239 240 Since: 2.31 241 242 @return: 243 """ 244 return None
245 - def resample( xres , yres , zres , interpolation ):
246 """ 247 Resamples a data brick. 248 249 In other words changes the size of three dimensional field related with data 250 brick. The original values are used for resampling using a requested 251 interpolation alorithm. 252 253 Since: 2.31 254 255 @param xres: Desired x resolution. I{(int)} 256 @param yres: Desired y resolution. I{(int)} 257 @param zres: Desired z resolution. I{(int)} 258 @param interpolation: Interpolation method to use. I{(InterpolationType)} 259 @return: 260 """ 261 return None
262 - def get_xres( ):
263 """ 264 Gets the x resolution of a data brick. 265 266 Since: 2.31 267 268 @return: Resolution (number of data points). 269 270 271 """ 272 return None
273 - def get_yres( ):
274 """ 275 Gets the y resolution of a data brick. 276 277 Since: 2.31 278 279 @return: Resolution (number of data points). 280 281 282 """ 283 return None
284 - def get_zres( ):
285 """ 286 Gets the z resolution of a data brick. 287 288 Since: 2.31 289 290 @return: Resolution (number of data points). 291 292 293 """ 294 return None
295 - def get_xreal( ):
296 """ 297 Gets the physical size of a data brick in the x direction. 298 299 Since: 2.31 300 301 @return: Real size of a data brick the x direction. 302 303 304 """ 305 return None
306 - def get_yreal( ):
307 """ 308 Gets the physical size of a data brick in the y direction. 309 310 Since: 2.31 311 312 @return: Real size of a data brick the y direction. 313 314 315 """ 316 return None
317 - def get_zreal( ):
318 """ 319 Gets the physical size of a data brick in the z direction. 320 321 Since: 2.31 322 323 @return: Real size of a data brick the z direction. 324 325 326 """ 327 return None
328 - def get_xoffset( ):
329 """ 330 Gets the offset of data brick origin in x direction. 331 332 Since: 2.31 333 334 @return: Offset value. 335 336 337 """ 338 return None
339 - def get_yoffset( ):
340 """ 341 Gets the offset of data brick origin in y direction. 342 343 Since: 2.31 344 345 @return: Offset value. 346 347 348 """ 349 return None
350 - def get_zoffset( ):
351 """ 352 Gets the offset of data brick origin in z direction. 353 354 Since: 2.31 355 356 @return: Offset value. 357 358 359 """ 360 return None
361 - def set_xreal( xreal ):
362 """ 363 Sets the real x dimension of a brick. 364 365 Since: 2.31 366 367 @param xreal: New real x dimensions value I{(float)} 368 @return: 369 """ 370 return None
371 - def set_yreal( yreal ):
372 """ 373 Sets the real y dimension of a brick. 374 375 Since: 2.31 376 377 @param yreal: New real y dimensions value I{(float)} 378 @return: 379 """ 380 return None
381 - def set_zreal( zreal ):
382 """ 383 Sets the real z dimension of a brick. 384 385 Since: 2.31 386 387 @param zreal: New real z dimensions value I{(float)} 388 @return: 389 """ 390 return None
391 - def set_xoffset( xoffset ):
392 """ 393 Sets the offset of a data brick origin in the x direction. 394 395 Note offsets don't affect any calculation, nor functions like 396 L{Brick.rtoi}(). 397 398 Since: 2.31 399 400 @param xoffset: New offset value. I{(float)} 401 @return: 402 """ 403 return None
404 - def set_yoffset( yoffset ):
405 """ 406 Sets the offset of a data brick origin in the y direction. 407 408 Note offsets don't affect any calculation, nor functions like 409 L{Brick.rtoi}(). 410 411 Since: 2.31 412 413 @param yoffset: New offset value. I{(float)} 414 @return: 415 """ 416 return None
417 - def set_zoffset( zoffset ):
418 """ 419 Sets the offset of a data brick origin in the z direction. 420 421 Note offsets don't affect any calculation, nor functions like 422 L{Brick.rtoi}(). 423 424 Since: 2.31 425 426 @param zoffset: New offset value. I{(float)} 427 @return: 428 """ 429 return None
430 - def get_si_unit_x( ):
431 """ 432 Returns x direction SI unit of a data brick. 433 434 Since: 2.31 435 436 @return: SI unit corresponding to the lateral (X) dimension of the data 437 brick. Its reference count is not incremented. 438 439 440 """ 441 return None
442 - def get_si_unit_y( ):
443 """ 444 Returns y direction SI unit of a data brick. 445 446 Since: 2.31 447 448 @return: SI unit corresponding to the lateral (Y) dimension of the data 449 brick. Its reference count is not incremented. 450 451 452 """ 453 return None
454 - def get_si_unit_z( ):
455 """ 456 Returns z direction SI unit of a data brick. 457 458 Since: 2.31 459 460 @return: SI unit corresponding to the "height" (Z) dimension of the data 461 brick. Its reference count is not incremented. 462 463 464 """ 465 return None
466 - def get_si_unit_w( ):
467 """ 468 Returns value SI unit of a data brick. 469 470 Since: 2.31 471 472 @return: SI unit corresponding to the "value" of the data 473 brick. Its reference count is not incremented. 474 475 476 """ 477 return None
478 - def set_si_unit_x( si_unit ):
479 """ 480 Sets the SI unit corresponding to the lateral (X) dimension of a data 481 brick. 482 483 It does not assume a reference on B{C{si_unit}}, instead it adds its own 484 reference. 485 486 Since: 2.31 487 488 @param si_unit: SI unit to be set. I{(L{SIUnit})} 489 @return: 490 """ 491 return None
492 - def set_si_unit_y( si_unit ):
493 """ 494 Sets the SI unit corresponding to the lateral (Y) dimension of a data 495 brick. 496 497 It does not assume a reference on B{C{si_unit}}, instead it adds its own 498 reference. 499 500 Since: 2.31 501 502 @param si_unit: SI unit to be set. I{(L{SIUnit})} 503 @return: 504 """ 505 return None
506 - def set_si_unit_z( si_unit ):
507 """ 508 Sets the SI unit corresponding to the "height" (Z) dimension of a data 509 brick. 510 511 It does not assume a reference on B{C{si_unit}}, instead it adds its own 512 reference. 513 514 Since: 2.31 515 516 @param si_unit: SI unit to be set. I{(L{SIUnit})} 517 @return: 518 """ 519 return None
520 - def set_si_unit_w( si_unit ):
521 """ 522 Sets the SI unit corresponding to the "value" of a data 523 brick. 524 525 It does not assume a reference on B{C{si_unit}}, instead it adds its own 526 reference. 527 528 Since: 2.31 529 530 @param si_unit: SI unit to be set. I{(L{SIUnit})} 531 @return: 532 """ 533 return None
534 - def get_min( ):
535 """ 536 Since: 2.31 537 538 @return: The minimum value within the brick. 539 540 541 """ 542 return None
543 - def get_max( ):
544 """ 545 Since: 2.31 546 547 @return: The maximum value within the brick. 548 549 550 """ 551 return None
552 - def UNIMPLEMENTED_get_value_format_x( style , format ):
553 """ 554 Finds value format good for displaying coordinates of a data brick. 555 556 Since: 2.31 557 558 @param style: Unit format style. I{(SIUnitFormatStyle)} 559 @param format: A SI value format to modify, or B{C{NULL}} to allocate a new one. I{(SIValueFormat*)} 560 @return: The value format. If B{C{format}} is B{C{NULL}}, a newly allocated format 561 is returned, otherwise (modified) B{C{format}} itself is returned. 562 563 564 """ 565 return None
566 - def UNIMPLEMENTED_get_value_format_y( style , format ):
567 """ 568 Finds value format good for displaying values of a data brick. 569 570 Since: 2.31 571 572 @param style: Unit format style. I{(SIUnitFormatStyle)} 573 @param format: A SI value format to modify, or B{C{NULL}} to allocate a new one. I{(SIValueFormat*)} 574 @return: The value format. If B{C{format}} is B{C{NULL}}, a newly allocated format 575 is returned, otherwise (modified) B{C{format}} itself is returned. 576 577 578 """ 579 return None
580 - def UNIMPLEMENTED_get_value_format_z( style , format ):
581 """ 582 Finds value format good for displaying values of a data brick. 583 584 Since: 2.31 585 586 @param style: Unit format style. I{(SIUnitFormatStyle)} 587 @param format: A SI value format to modify, or B{C{NULL}} to allocate a new one. I{(SIValueFormat*)} 588 @return: The value format. If B{C{format}} is B{C{NULL}}, a newly allocated format 589 is returned, otherwise (modified) B{C{format}} itself is returned. 590 591 592 """ 593 return None
594 - def UNIMPLEMENTED_get_value_format_w( style , format ):
595 """ 596 Finds value format good for displaying values of a data brick. 597 598 Note this functions searches for minimum and maximum value in B{C{brick}}, 599 therefore it's relatively slow. 600 601 Since: 2.31 602 603 @param style: Unit format style. I{(SIUnitFormatStyle)} 604 @param format: A SI value format to modify, or B{C{NULL}} to allocate a new one. I{(SIValueFormat*)} 605 @return: The value format. If B{C{format}} is B{C{NULL}}, a newly allocated format 606 is returned, otherwise (modified) B{C{format}} itself is returned. 607 608 609 """ 610 return None
611 - def get_data( ):
612 """ 613 Gets the raw data buffer of a data brick. 614 615 The returned buffer is not guaranteed to be valid through whole data 616 brick life time. Some function may change it, most notably 617 L{Brick.resample}(). 618 619 This function invalidates any cached information, use 620 L{Brick.get_data_const}() if you are not going to change the data. 621 622 Since: 2.31 623 624 @return: The data as an array of doubles of length B{C{xres}}*B{C{yres}}*B{C{zres}}. 625 626 627 """ 628 return None
629 - def itor( pixpos ):
630 """ 631 Transforms pixel coordinate to real (physical) coordinate in x direction. 632 633 That is it maps range [0..x resolution] to range [0..x real-size]. It is not 634 suitable for conversion of matrix indices to physical coordinates, you 635 have to use L{Brick.itor}(B{C{brick}}, B{C{pixpos}} + 0.5) for that. 636 637 Since: 2.31 638 639 @param pixpos: Pixel coordinate. I{(float)} 640 @return: B{C{pixpos}} in real coordinates. 641 642 643 """ 644 return None
645 - def rtoi( realpos ):
646 """ 647 Transforms real (physical) coordinate to pixel coordinate in x axis. 648 649 That is it maps range [0..x real-size] to range [0..x resolution]. 650 651 Since: 2.31 652 653 @param realpos: Real coordinate. I{(float)} 654 @return: B{C{realpos}} in pixel coordinates. 655 656 657 """ 658 return None
659 - def jtor( pixpos ):
660 """ 661 Transforms pixel coordinate to real (physical) coordinate in y direction. 662 663 That is it maps range [0..y resolution] to range [0..y real-size]. It is not 664 suitable for conversion of matrix indices to physical coordinates, you 665 have to use L{Brick.itor}(B{C{brick}}, B{C{pixpos}} + 0.5) for that. 666 667 Since: 2.31 668 669 @param pixpos: Pixel coordinate. I{(float)} 670 @return: B{C{pixpos}} in real coordinates. 671 672 673 """ 674 return None
675 - def rtoj( realpos ):
676 """ 677 Transforms real (physical) coordinate to pixel coordinate in y axis. 678 679 That is it maps range [0..y real-size] to range [0..y resolution]. 680 681 Since: 2.31 682 683 @param realpos: Real coordinate. I{(float)} 684 @return: B{C{realpos}} in pixel coordinates. 685 686 687 """ 688 return None
689 - def ktor( pixpos ):
690 """ 691 Transforms pixel coordinate to real (physical) coordinate in z direction. 692 693 That is it maps range [0..z resolution] to range [0..z real-size]. It is not 694 suitable for conversion of matrix indices to physical coordinates, you 695 have to use L{Brick.itor}(B{C{brick}}, B{C{pixpos}} + 0.5) for that. 696 697 Since: 2.31 698 699 @param pixpos: Pixel coordinate. I{(float)} 700 @return: B{C{pixpos}} in real coordinates. 701 702 703 """ 704 return None
705 - def rtok( realpos ):
706 """ 707 Transforms real (physical) coordinate to pixel coordinate in z axis. 708 709 That is it maps range [0..z real-size] to range [0..z resolution]. 710 711 Since: 2.31 712 713 @param realpos: Real coordinate. I{(float)} 714 @return: B{C{realpos}} in pixel coordinates. 715 716 717 """ 718 return None
719 - def ktor_cal( pixpos ):
720 """ 721 Transforms pixel coordinate to real (physical) coordinate in z direction, 722 taking into account calibration. 723 724 Unlike L{Brick.ktor}(), this function takes into account the B{C{z}} 725 calibration and, if calibration is not present, the B{C{z}} axis offset. 726 Since the calibration is available only for discrete pixel coordinates, 727 the values are interpolated between and clamped if outside the range. 728 729 The values in the calibration are assumed to correspond to pixel centres. 730 This convention is also kept when no calibration is present. 731 732 Since: 2.42 733 734 @param pixpos: Pixel coordinate. I{(float)} 735 @return: B{C{pixpos}} in real coordinates. 736 737 738 """ 739 return None
740 - def rtok_cal( realpos ):
741 """ 742 Transforms real (physical) coordinate to pixel coordinate in z axis, 743 taking into account calibration. 744 745 Unlike L{Brick.rtok}(), this function takes into account the B{C{z}} 746 calibration and, if calibration is not present, the B{C{z}} axis offset. 747 Since the calibration is available only for discrete pixel coordinates, 748 the values are interpolated between and clamped if outside the range. 749 750 The values in the calibration are assumed to correspond to pixel centres. 751 This convention is also kept when no calibration is present. 752 753 Since: 2.42 754 755 @param realpos: Real coordinate. I{(float)} 756 @return: B{C{realpos}} in pixel coordinates. 757 758 759 """ 760 return None
761 - def get_val( col , row , lev ):
762 """ 763 Gets value at given position in a data brick. 764 765 Do not access data with this function inside inner loops, it's slow. 766 Get raw data buffer with L{Brick.get_data_const}() and access it 767 directly instead. 768 769 Since: 2.31 770 771 @param col: Position in the brick (column index). I{(int)} 772 @param row: Position in the brick (row index). I{(int)} 773 @param lev: Position in the brick (level index). I{(int)} 774 @return: Value at given index. 775 776 777 """ 778 return None
779 - def set_val( col , row , lev , value ):
780 """ 781 Sets value at given position in a data brick. 782 783 Do not access data with this function inside inner loops, it's slow. 784 Get raw data buffer with L{Brick.get_data_const}() and access it 785 directly instead. 786 787 Since: 2.31 788 789 @param col: Position in the brick (column index). I{(int)} 790 @param row: Position in the brick (row index). I{(int)} 791 @param lev: Position in the brick (level index). I{(int)} 792 @param value: Value to be set. I{(float)} 793 @return: 794 """ 795 return None
796 - def get_val_real( x , y , z ):
797 """ 798 Gets value at given position in a data brick, in real coordinates. 799 800 Do not access data with this function inside inner loops, it's slow. 801 Get raw data buffer with L{Brick.get_data_const}() and access it 802 directly instead. 803 804 Since: 2.31 805 806 @param x: Position in the brick (x direction). I{(float)} 807 @param y: Position in the brick (y direction). I{(float)} 808 @param z: Position in the brick (z direction). I{(float)} 809 @return: Value at given index. 810 811 812 """ 813 return None
814 - def set_val_real( x , y , z , value ):
815 """ 816 Sets value at given position in a data brick. 817 818 Do not access data with this function inside inner loops, it's slow. 819 Get raw data buffer with L{Brick.get_data_const}() and access it 820 directly instead. 821 822 Since: 2.31 823 824 @param x: Position in the brick (x direction). I{(float)} 825 @param y: Position in the brick (y direction). I{(float)} 826 @param z: Position in the brick (z direction). I{(float)} 827 @param value: Value to be set. I{(float)} 828 @return: 829 """ 830 return None
831 - def get_dval( x , y , z , interpolation ):
832 """ 833 Gets interpolated value at arbitrary data brick point indexed by pixel 834 coordinates. 835 836 Note pixel values are centered in intervals [B{C{i}}, B{C{i}}+1]. 837 See also L{Brick.get_dval_real}() that does the same, but takes 838 real coordinates. 839 840 Since: 2.31 841 842 @param x: Position in data brick in range [0, x resolution]. If the value is outside 843 this range, the nearest border value is returned. I{(float)} 844 @param y: Position in data brick in range [0, y resolution]. If the value is outside 845 this range, the nearest border value is returned. I{(float)} 846 @param z: Position in data brick in range [0, z resolution]. If the value is outside 847 this range, the nearest border value is returned. I{(float)} 848 @param interpolation: Interpolation method to use. I{(int)} 849 @return: Value interpolated in the data brick. 850 851 852 """ 853 return None
854 - def get_dval_real( x , y , z , interpolation ):
855 """ 856 Gets interpolated value at arbitrary data brick point indexed by pixel 857 coordinates. 858 859 Note pixel values are centered in intervals [B{C{j}}, B{C{j}}+1]. 860 See also L{Brick.get_dval}() that does the same, but takes 861 pixel coordinates. 862 863 Since: 2.31 864 865 @param x: Position in data brick in range [0, x resolution]. If the value is outside 866 this range, the nearest border value is returned. I{(float)} 867 @param y: Position in data brick in range [0, y resolution]. If the value is outside 868 this range, the nearest border value is returned. I{(float)} 869 @param z: Position in data brick in range [0, z resolution]. If the value is outside 870 this range, the nearest border value is returned. I{(float)} 871 @param interpolation: Interpolation method to use. I{(int)} 872 @return: Value interpolated in the data brick. 873 874 875 """ 876 return None
877 - def clear( ):
878 """ 879 Fills a data brick with zeroes. 880 881 Since: 2.31 882 883 @return: 884 """ 885 return None
886 - def fill( value ):
887 """ 888 Fills a data brick with specified value. 889 890 Since: 2.31 891 892 @param value: Value to fill data brick with. I{(float)} 893 @return: 894 """ 895 return None
896 - def multiply( value ):
897 """ 898 Multiplies all values in a data brick with a specified value. 899 900 Since: 2.31 901 902 @param value: Value to multiply data brick with. I{(float)} 903 @return: 904 """ 905 return None
906 - def add( value ):
907 """ 908 Adds a specified value to all values in a data brick. 909 910 Since: 2.31 911 912 @param value: Value to be added. I{(float)} 913 @return: 914 """ 915 return None
916 - def extract_plane( target , istart , jstart , kstart , width , height , depth , keep_offsets ):
917 """ 918 Extract a plane (DataField) from the brick. 919 920 One value of set (B{C{width}}, B{C{height}}, B{C{depth}}) needs to be -1, determining the 921 plane orientation. 922 923 Since: 2.31 924 925 @param target: Datafield to be filled by extracted plane. It will be resized if 926 necessary. I{(L{DataField})} 927 @param istart: Column where to start (pixel coordinates). I{(int)} 928 @param jstart: Row where to start (pixel coordinates). I{(int)} 929 @param kstart: Level where to start (pixel coordinates). I{(int)} 930 @param width: Pixel width of extracted plane. If B{C{width}} is -1, the yz plane will 931 be extracted. I{(int)} 932 @param height: Pixel height of extracted plane. If B{C{height}} is -1, the xz plane 933 will be extracted I{(int)} 934 @param depth: Pixel depth of extracted plane. If B{C{depth}} is -1, the xy plane will 935 be extracted I{(int)} 936 @param keep_offsets: Keep the physical offsets in extracted field. I{(bool)} 937 @return: 938 """ 939 return None
940 - def sum_plane( target , istart , jstart , kstart , width , height , depth , keep_offsets ):
941 """ 942 Sums planes in certain direction and extract the result (DataField). One 943 value of set (B{C{width}}, B{C{height}}, B{C{depth}}) needs to be -1, determining the plane 944 orientation. In contrast to L{Brick.extract_plane}, the appropriate start 945 coordinate (e.g. B{C{istart}} if B{C{width}} = -1) is not used for single plane 946 extraction, but the planes are accumulated in whole range (0..xres for given 947 example) 948 949 Since: 2.31 950 951 @param target: Datafield to be filled by summed plane. It will be resized if 952 necessary. I{(L{DataField})} 953 @param istart: Column where to start (pixel coordinates). I{(int)} 954 @param jstart: Row where to start (pixel coordinates). I{(int)} 955 @param kstart: Level where to start (pixel coordinates). I{(int)} 956 @param width: Pixel width of summed plane. If B{C{width}} is -1, the yz planes will be 957 summed. I{(int)} 958 @param height: Pixel height of summed plane. If B{C{height}} is -1, the xz planes will 959 be summed I{(int)} 960 @param depth: Pixel depth of summed plane. If B{C{depth}} is -1, the xy planes will 961 be summed I{(int)} 962 @param keep_offsets: Keep the physical offsets in extracted field. Not 963 implemented. I{(bool)} 964 @return: 965 """ 966 return None
967 - def min_plane( target , istart , jstart , kstart , width , height , depth , keep_offsets ):
968 """ 969 Finds minima of planes in certain direction and extract the result 970 (DataField). One value of set (B{C{width}}, B{C{height}}, B{C{depth}}) needs to be -1, 971 determining the plane orientation. In contrast to L{Brick.extract_plane}, 972 the appropriate start coordinate (e.g. B{C{istart}} if B{C{width}} = -1) is not used 973 for single plane extraction, but the planes are accumulated in whole range 974 (0..xres for given example) 975 976 Since: 2.32 977 978 @param target: Datafield to be filled by the minima plane. It will be resized if 979 necessary. I{(L{DataField})} 980 @param istart: Column where to start (pixel coordinates). I{(int)} 981 @param jstart: Row where to start (pixel coordinates). I{(int)} 982 @param kstart: Level where to start (pixel coordinates). I{(int)} 983 @param width: Pixel width of summarized plane. If B{C{width}} is -1, the yz planes will 984 be summarized. I{(int)} 985 @param height: Pixel height of summarized plane. If B{C{height}} is -1, the xz planes 986 will be summarized. I{(int)} 987 @param depth: Pixel depth of summarized plane. If B{C{depth}} is -1, the xy planes will 988 be summarized I{(int)} 989 @param keep_offsets: Keep the physical offsets in extracted field. Not 990 implemented. I{(bool)} 991 @return: 992 """ 993 return None
994 - def max_plane( target , istart , jstart , kstart , width , height , depth , keep_offsets ):
995 """ 996 Finds minima of planes in certain direction and extract the result 997 (DataField). One value of set (B{C{width}}, B{C{height}}, B{C{depth}}) needs to be -1, 998 determining the plane orientation. In contrast to L{Brick.extract_plane}, 999 the appropriate start coordinate (e.g. B{C{istart}} if B{C{width}} = -1) is not used 1000 for single plane extraction, but the planes are accumulated in whole range 1001 (0..xres for given example) 1002 1003 Since: 2.32 1004 1005 @param target: Datafield to be filled by the maxima plane. It will be resized if 1006 necessary. I{(L{DataField})} 1007 @param istart: Column where to start (pixel coordinates). I{(int)} 1008 @param jstart: Row where to start (pixel coordinates). I{(int)} 1009 @param kstart: Level where to start (pixel coordinates). I{(int)} 1010 @param width: Pixel width of summarized plane. If B{C{width}} is -1, the yz planes will 1011 be summarized. I{(int)} 1012 @param height: Pixel height of summarized plane. If B{C{height}} is -1, the xz planes 1013 will be summarized. I{(int)} 1014 @param depth: Pixel depth of extracted plane. If B{C{depth}} is -1, the xy planes will 1015 be summarized I{(int)} 1016 @param keep_offsets: Keep the physical offsets in extracted field. Not 1017 implemented. I{(bool)} 1018 @return: 1019 """ 1020 return None
1021 - def minpos_plane( target , istart , jstart , kstart , width , height , depth , keep_offsets ):
1022 """ 1023 Finds minima positions of planes in certain direction and extract the result 1024 (DataField). One value of set (B{C{width}}, B{C{height}}, B{C{depth}}) needs to be -1, 1025 determining the plane orientation. In contrast to L{Brick.extract_plane}, 1026 the appropriate start coordinate (e.g. B{C{istart}} if B{C{width}} = -1) is not used 1027 for single plane extraction, but the planes are accumulated in whole range 1028 (0..xres for given example) 1029 1030 Since: 2.32 1031 1032 @param target: Datafield to be filled by the minima positions plane. 1033 It will be resized if necessary. I{(L{DataField})} 1034 @param istart: Column where to start (pixel coordinates). I{(int)} 1035 @param jstart: Row where to start (pixel coordinates). I{(int)} 1036 @param kstart: Level where to start (pixel coordinates). I{(int)} 1037 @param width: Pixel width of summarized plane. If B{C{width}} is -1, the yz planes will 1038 be summarized. I{(int)} 1039 @param height: Pixel height of summarized plane. If B{C{height}} is -1, the xz planes 1040 will be summarized. I{(int)} 1041 @param depth: Pixel depth of summarized plane. If B{C{depth}} is -1, the xy planes will 1042 be summarized I{(int)} 1043 @param keep_offsets: Keep the physical offsets in summarized field. Not 1044 implemented. I{(bool)} 1045 @return: 1046 """ 1047 return None
1048 - def maxpos_plane( target , istart , jstart , kstart , width , height , depth , keep_offsets ):
1049 """ 1050 Finds maxima positions of planes in certain direction and extract the result 1051 (DataField). One value of set (B{C{width}}, B{C{height}}, B{C{depth}}) needs to be -1, 1052 determining the plane orientation. In contrast to L{Brick.extract_plane}, 1053 the appropriate start coordinate (e.g. B{C{istart}} if B{C{width}} = -1) is not used 1054 for single plane extraction, but the planes are accumulated in whole range 1055 (0..xres for given example) 1056 1057 Since: 2.32 1058 1059 @param target: Datafield to be filled by the maxima positions plane. 1060 It will be resized if necessary. I{(L{DataField})} 1061 @param istart: Column where to start (pixel coordinates). I{(int)} 1062 @param jstart: Row where to start (pixel coordinates). I{(int)} 1063 @param kstart: Level where to start (pixel coordinates). I{(int)} 1064 @param width: Pixel width of summarized plane. If B{C{width}} is -1, the yz planes will 1065 be summarized. I{(int)} 1066 @param height: Pixel height of summarized plane. If B{C{height}} is -1, the xz planes 1067 will be summarized I{(int)} 1068 @param depth: Pixel depth of summarized plane. If B{C{depth}} is -1, the xy planes will 1069 be summarized I{(int)} 1070 @param keep_offsets: Keep the physical offsets in summarized field. Not 1071 implemented. I{(bool)} 1072 @return: 1073 """ 1074 return None
1075 - def mean_plane( target , istart , jstart , kstart , width , height , depth , keep_offsets ):
1076 """ 1077 Finds mean of planes in certain direction and extract the result 1078 (DataField). One value of set (B{C{width}}, B{C{height}}, B{C{depth}}) needs to be -1, 1079 determining the plane orientation. In contrast to L{Brick.extract_plane}, 1080 the appropriate start coordinate (e.g. B{C{istart}} if B{C{width}} = -1) is not used 1081 for single plane extraction, but the planes are accumulated in whole range 1082 (0..xres for given example) 1083 1084 Since: 2.32 1085 1086 @param target: Datafield to be filled by the mean plane. It will be resized if 1087 necessary. I{(L{DataField})} 1088 @param istart: Column where to start (pixel coordinates). I{(int)} 1089 @param jstart: Row where to start (pixel coordinates). I{(int)} 1090 @param kstart: Level where to start (pixel coordinates). I{(int)} 1091 @param width: Pixel width of summarized plane. If B{C{width}} is -1, the yz planes will 1092 be summarized. I{(int)} 1093 @param height: Pixel height of summarized plane. If B{C{height}} is -1, the xz planes 1094 will be summarized. I{(int)} 1095 @param depth: Pixel depth of summarized plane. If B{C{depth}} is -1, the xy planes will 1096 be summarized. I{(int)} 1097 @param keep_offsets: Keep the physical offsets in summarized field. Not 1098 implemented. I{(bool)} 1099 @return: 1100 """ 1101 return None
1102 - def rms_plane( target , istart , jstart , kstart , width , height , depth , keep_offsets ):
1103 """ 1104 Finds rms of planes in certain direction and extract the result 1105 (DataField). One value of set (B{C{width}}, B{C{height}}, B{C{depth}}) needs to be -1, 1106 determining the plane orientation. In contrast to L{Brick.extract_plane}, 1107 the appropriate start coordinate (e.g. B{C{istart}} if B{C{width}} = -1) is not used 1108 for single plane extraction, but the planes are accumulated in whole range 1109 (0..xres for given example) 1110 1111 Since: 2.32 1112 1113 @param target: Datafield to be filled by the rms plane. It will be resized if 1114 necessary. I{(L{DataField})} 1115 @param istart: Column where to start (pixel coordinates). I{(int)} 1116 @param jstart: Row where to start (pixel coordinates). I{(int)} 1117 @param kstart: Level where to start (pixel coordinates). I{(int)} 1118 @param width: Pixel width of summarized plane. If B{C{width}} is -1, the yz planes will 1119 be summarized. I{(int)} 1120 @param height: Pixel height of summarized plane. If B{C{height}} is -1, the xz planes 1121 will be summarized. I{(int)} 1122 @param depth: Pixel depth of summarized plane. If B{C{depth}} is -1, the xy planes will 1123 be summarized. I{(int)} 1124 @param keep_offsets: Keep the physical offsets in extracted field. Not 1125 implemented. I{(bool)} 1126 @return: 1127 """ 1128 return None
1129 - def extract_line( target , istart , jstart , kstart , iend , jend , kend , keep_offsets ):
1130 """ 1131 Extract a line (DataLine) from the brick. 1132 1133 Only line orientations parallel to coordinate axes are supported now, i.e. 1134 two of the start coordinates need to be same as end ones. 1135 1136 Since: 2.31 1137 1138 @param target: Dataline to be filled by extracted line. It will be resized if 1139 necessary. I{(L{DataLine})} 1140 @param istart: Column where to start (pixel coordinates). I{(int)} 1141 @param jstart: Row where to start (pixel coordinates). I{(int)} 1142 @param kstart: Level where to start (pixel coordinates). I{(int)} 1143 @param iend: Column where to start (pixel coordinates). I{(int)} 1144 @param jend: Row where to start (pixel coordinates). I{(int)} 1145 @param kend: Level where to start (pixel coordinates). I{(int)} 1146 @param keep_offsets: Keep physical offsets in extracted line. I{(bool)} 1147 @return: 1148 """ 1149 return None
1150 - def get_zcalibration( ):
1151 """ 1152 Gets the z-axis non-linear calibration of a data brick. 1153 1154 Since: 2.32 1155 1156 @return: Z Calibration (non-linear Z-axis values as ordinates). 1157 1158 1159 """ 1160 return None
1161 - def set_zcalibration( calibration ):
1162 """ 1163 Sets the z-axis non-linear calibration of a data brick. 1164 1165 Since: 2.32 1166 1167 @param calibration: DataLine pointer with z-axis non-linear calibration 1168 of a data brick (values are stored as ordinates). It can also 1169 be B{C{NULL}} to unset the calibration. I{(L{DataLine})} 1170 @return: 1171 """ 1172 return None
1173 - def UNIMPLEMENTED_invert( brick , x , y , z ):
1174 return None
1175 - def duplicate( ):
1176 """ 1177 Duplicate brick 1178 1179 1180 @return: duplicated brick 1181 1182 """ 1183 return None
1184 - def get_data_pointer( ):
1185 """ 1186 Get Pointer to data which the brick contains. 1187 1188 1189 @return: integer pointing to the raw data of the brick 1190 1191 """ 1192 return None
1193 -class ColorAxis:
1194 - def __init__( orientation ):
1195 """ 1196 Creates a new color axis. 1197 1198 1199 @return: The newly created color axis as a B{C{GtkWidget}}. 1200 1201 """ 1202 return None
1203 - def get_range( min , max ):
1204 """ 1205 Gets the range of a color axis. 1206 1207 @param min: Location to store the range maximum (or B{C{NULL}}). I{(float)} 1208 @param max: Location to store the range minimum (or B{C{NULL}}). I{(float)} 1209 @return: 1210 """ 1211 return None
1212 - def set_range( min , max ):
1213 """ 1214 Sets the range of a color axis. 1215 1216 @param min: The range minimum. I{(float)} 1217 @param max: The range maximum. I{(float)} 1218 @return: 1219 """ 1220 return None
1221 - def get_si_unit( ):
1222 """ 1223 Gets the SI unit a color axis displays. 1224 1225 1226 @return: The SI unit. 1227 1228 """ 1229 return None
1230 - def set_si_unit( unit ):
1231 """ 1232 Sets the SI unit a color axis displays. 1233 1234 @param unit: A SI unit to display next to minimum and maximum value. I{(L{SIUnit})} 1235 @return: 1236 """ 1237 return None
1238 - def set_gradient( gradient ):
1239 """ 1240 Sets the color gradient a color axis should use. 1241 1242 @param gradient: Name of gradient B{C{axis}} should use. It should exist. I{(string)} 1243 @return: 1244 """ 1245 return None
1246 - def get_gradient( ):
1247 """ 1248 Gets the color gradient a color axis uses. 1249 1250 1251 @return: The color gradient. 1252 1253 """ 1254 return None
1255 - def get_ticks_style( ):
1256 """ 1257 Gets ticks style of a color axis. 1258 1259 1260 @return: The ticks style. 1261 1262 """ 1263 return None
1264 - def set_ticks_style( ticks_style ):
1265 """ 1266 Sets the ticks style of a color axis. 1267 1268 @param ticks_style: The ticks style to use. I{(TicksStyle)} 1269 @return: 1270 """ 1271 return None
1272 - def get_labels_visible( ):
1273 """ 1274 Gets the visibility of labels of a color axis. 1275 1276 1277 @return: B{C{True}} if labels are displayed, B{C{False}} if they are omitted. 1278 1279 """ 1280 return None
1281 - def set_labels_visible( labels_visible ):
1282 """ 1283 Sets the visibility of labels of a color axis. 1284 1285 @param labels_visible: B{C{True}} to display labels with minimum and maximum values, 1286 B{C{False}} to display no labels. I{(bool)} 1287 @return: 1288 """ 1289 return None
1290 - def UNIMPLEMENTED_set_tick_map_func( func , user_data ):
1291 """ 1292 Set the tick mapping function for a color axis. 1293 1294 The axis calculates tick positions as for the linear axis and then places 1295 them non-linearly using B{C{func}}. Hence a mapping function should be used with 1296 ticks mode B{C{TICKS_STYLE_UNLABELLED}} because minimum tick spacing is not 1297 guaranteed. 1298 1299 Since: 2.39 1300 1301 @param func: Tick mapping function. I{(ColorAxisMapFunc)} 1302 @param user_data: Data to pass to B{C{func}}. I{(gpointer)} 1303 @return: 1304 """ 1305 return None
1306 -class ColorButton:
1307 - def __init__( ):
1308 """ 1309 Creates a new color button. This returns a widget in the form of 1310 a small button containing a swatch representing the current selected 1311 color. When the button is clicked, a color-selection dialog will open, 1312 allowing the user to select a color. The swatch will be updated to reflect 1313 the new color when the user finishes. 1314 1315 1316 @return: a new color button. 1317 1318 """ 1319 return None
1320 - def set_color( color ):
1321 """ 1322 Sets the current color to be B{C{color}}. 1323 1324 @param color: A B{C{RGBA}} to set the current color with. I{(L{RGBA})} 1325 @return: 1326 """ 1327 return None
1328 - def get_color( color ):
1329 """ 1330 Sets B{C{color}} to be the current color in the B{C{ColorButton}} widget. 1331 1332 @param color: a B{C{RGBA}} to fill in with the current color. I{(L{RGBA})} 1333 @return: 1334 """ 1335 return None
1336 - def set_use_alpha( use_alpha ):
1337 """ 1338 Sets whether or not the color button should use the alpha channel. 1339 1340 @param use_alpha: B{C{True}} if color button should use alpha channel, B{C{False}} if not. I{(bool)} 1341 @return: 1342 """ 1343 return None
1344 - def get_use_alpha( ):
1345 """ 1346 Does the color selection dialog use the alpha channel? 1347 1348 1349 @return: B{C{True}} if the color sample uses alpha channel, B{C{False}} if not. 1350 1351 """ 1352 return None
1353 -class Container:
1354 - def __init__( ):
1355 """ 1356 Creates a new B{C{Container}}. 1357 1358 1359 @return: The container, as a B{C{GObject}}. 1360 1361 """ 1362 return None
1363 - def get_n_items( ):
1364 """ 1365 Gets the number of items in a container. 1366 1367 1368 @return: The number of items. 1369 1370 """ 1371 return None
1372 - def value_type( key ):
1373 """ 1374 Returns the type of value in B{C{container}} identified by B{C{key}}. 1375 1376 1377 @param key: A B{C{GQuark}} key. I{(int)} 1378 @return: The value type as B{C{GType}}; 0 if there is no such value. 1379 1380 """ 1381 return None
1382 - def contains( key ):
1383 """ 1384 Returns B{C{True}} if B{C{container}} contains a value identified by B{C{key}}. 1385 1386 1387 @param key: A B{C{GQuark}} key. I{(int)} 1388 @return: Whether B{C{container}} contains something identified by B{C{key}}. 1389 1390 """ 1391 return None
1392 - def get_value( key ):
1393 """ 1394 Returns the value in B{C{container}} identified by B{C{key}}. 1395 1396 1397 @param key: A B{C{GQuark}} key. I{(int)} 1398 @return: The value as a B{C{GValue}}. 1399 1400 """ 1401 return None
1402 - def UNIMPLEMENTED_gis_value( key , value ):
1403 """ 1404 Get-if-set a generic value from a container. 1405 1406 1407 @param key: A B{C{GQuark}} key. I{(int)} 1408 @param value: Pointer to a B{C{GValue}} to update. If item does not exist, 1409 it is left untouched. I{(GValue*)} 1410 @return: B{C{True}} if B{C{v}} was actually updated, B{C{False}} when there is no 1411 such value in the container. 1412 1413 """ 1414 return None
1415 - def remove( key ):
1416 """ 1417 Removes a value identified by B{C{key}} from a container. 1418 1419 1420 @param key: A B{C{GQuark}} key. I{(int)} 1421 @return: B{C{True}} if there was such a value and was removed. 1422 1423 """ 1424 return None
1425 - def remove_by_prefix( prefix ):
1426 """ 1427 Removes a values whose key start with B{C{prefix}} from container B{C{container}}. 1428 1429 B{C{prefix}} can be B{C{NULL}}, all values are then removed. 1430 1431 1432 @param prefix: A nul-terminated id prefix. I{(string)} 1433 @return: The number of values removed. 1434 1435 """ 1436 return None
1437 - def transfer( dest , source_prefix , dest_prefix , force ):
1438 """ 1439 Copies a items from one place in container to another place. 1440 1441 The copies are shallow, objects are not physically duplicated, only 1442 referenced in B{C{dest}}. 1443 1444 1445 @param dest: Destination container. It may be the same container as B{C{source}}, but 1446 B{C{source_prefix}} and B{C{dest_prefix}} may not overlap then. I{(L{Container})} 1447 @param source_prefix: Prefix in B{C{source}} to take values from. I{(string)} 1448 @param dest_prefix: Prefix in B{C{dest}} to put values to. I{(string)} 1449 @param force: B{C{True}} to replace existing values in B{C{dest}}. I{(bool)} 1450 @return: The number of actually transferred items. 1451 1452 """ 1453 return None
1454 - def rename( key , newkey , force ):
1455 """ 1456 Makes a value in B{C{container}} identified by B{C{key}} to be identified by B{C{newkey}}. 1457 1458 When B{C{force}} is B{C{True}} existing value at B{C{newkey}} is removed from B{C{container}}. 1459 When it's B{C{False}}, an existing value B{C{newkey}} inhibits the rename and B{C{False}} 1460 is returned. 1461 1462 1463 @param key: The current key. I{(int)} 1464 @param newkey: A new key for the value. I{(int)} 1465 @param force: Whether to replace existing value at B{C{newkey}}. I{(bool)} 1466 @return: Whether the rename succeeded. 1467 1468 """ 1469 return None
1470 - def UNIMPLEMENTED_foreach( prefix , function , user_data ):
1471 """ 1472 Calls B{C{function}} on each B{C{container}} item whose identifier starts with 1473 B{C{prefix}}. 1474 1475 The function is called B{C{function}}(B{C{GQuark}} key, B{C{GValue}} *value, user_data). 1476 1477 1478 @param prefix: A nul-terminated id prefix. I{(string)} 1479 @param function: The function called on the items. I{(GHFunc)} 1480 @param user_data: The user data passed to B{C{function}}. I{(gpointer)} 1481 @return: The number of items B{C{function}} was called on. 1482 1483 """ 1484 return None
1485 - def keys( ):
1486 """ 1487 Gets all quark keys of a container. 1488 1489 Since: 2.7 1490 1491 @return: A newly allocated array with quark keys of all B{C{container}} items, 1492 in no particular order. The number of items can be obtained 1493 with L{Container.get_n_items}(). If there are no items, B{C{NULL}} 1494 is returned. 1495 1496 1497 """ 1498 return None
1499 - def keys_by_name( ):
1500 """ 1501 Gets all string keys of a container. 1502 1503 Since: 2.7 1504 1505 @return: A newly allocated array with string keys of all B{C{container}} items, 1506 in no particular order. The number of items can be obtained 1507 with L{Container.get_n_items}(). If there are no items, B{C{NULL}} 1508 is returned. Unlike the array the strings are owned by GLib and 1509 must not be freed. 1510 1511 1512 """ 1513 return None
1514 - def set_boolean( key , value ):
1515 """ 1516 Stores a boolean into B{C{container}}, identified by B{C{key}}. 1517 1518 @param key: A B{C{GQuark}} key. I{(int)} 1519 @param value: A boolean. I{(bool)} 1520 @return: 1521 """ 1522 return None
1523 - def get_boolean( key ):
1524 """ 1525 Returns the boolean in B{C{container}} identified by B{C{key}}. 1526 1527 1528 @param key: A B{C{GQuark}} key. I{(int)} 1529 @return: The boolean as B{C{gboolean}}. 1530 1531 """ 1532 return None
1533 - def UNIMPLEMENTED_gis_boolean( key , value ):
1534 """ 1535 Get-if-set a boolean from a container. 1536 1537 1538 @param key: A B{C{GQuark}} key. I{(int)} 1539 @param value: Pointer to the boolean to update. I{(gboolean*)} 1540 @return: B{C{True}} if B{C{v}} was actually updated, B{C{False}} when there is no 1541 such boolean in the container. 1542 1543 """ 1544 return None
1545 - def set_uchar( key , value ):
1546 """ 1547 Stores an unsigned character into B{C{container}}, identified by B{C{key}}. 1548 1549 @param key: A B{C{GQuark}} key. I{(int)} 1550 @param value: An unsigned character. I{(guchar)} 1551 @return: 1552 """ 1553 return None
1554 - def get_uchar( key ):
1555 """ 1556 Returns the unsigned character in B{C{container}} identified by B{C{key}}. 1557 1558 1559 @param key: A B{C{GQuark}} key. I{(int)} 1560 @return: The character as B{C{guchar}}. 1561 1562 """ 1563 return None
1564 - def UNIMPLEMENTED_gis_uchar( key , value ):
1565 """ 1566 Get-if-set an unsigned char from a container. 1567 1568 1569 @param key: A B{C{GQuark}} key. I{(int)} 1570 @param value: Pointer to the unsigned char to update. I{(guchar*)} 1571 @return: B{C{True}} if B{C{v}} was actually updated, B{C{False}} when there is no 1572 such unsigned char in the container. 1573 1574 """ 1575 return None
1576 - def set_int32( key , value ):
1577 """ 1578 Stores a 32bit integer into B{C{container}}, identified by B{C{key}}. 1579 1580 @param key: A B{C{GQuark}} key. I{(int)} 1581 @param value: A 32bit integer. I{(int)} 1582 @return: 1583 """ 1584 return None
1585 - def get_int32( key ):
1586 """ 1587 Returns the 32bit integer in B{C{container}} identified by B{C{key}}. 1588 1589 1590 @param key: A B{C{GQuark}} key. I{(int)} 1591 @return: The integer as B{C{guint32}}. 1592 1593 """ 1594 return None
1595 - def UNIMPLEMENTED_gis_int32( key , value ):
1596 """ 1597 Get-if-set a 32bit integer from a container. 1598 1599 1600 @param key: A B{C{GQuark}} key. I{(int)} 1601 @param value: Pointer to the 32bit integer to update. I{(int)} 1602 @return: B{C{True}} if B{C{v}} was actually updated, B{C{False}} when there is no 1603 such 32bit integer in the container. 1604 1605 """ 1606 return None
1607 - def set_enum( key , value ):
1608 """ 1609 Stores an enum into B{C{container}}, identified by B{C{key}}. 1610 1611 Note enums are treated as 32bit integers. 1612 1613 @param key: A B{C{GQuark}} key. I{(int)} 1614 @param value: An enum integer. I{(int)} 1615 @return: 1616 """ 1617 return None
1618 - def get_enum( key ):
1619 """ 1620 Returns the enum in B{C{container}} identified by B{C{key}}. 1621 1622 Note enums are treated as 32bit integers. 1623 1624 1625 @param key: A B{C{GQuark}} key. I{(int)} 1626 @return: The enum as B{C{gint}}. 1627 1628 """ 1629 return None
1630 - def UNIMPLEMENTED_gis_enum( key , value ):
1631 """ 1632 Get-if-set an enum from a container. 1633 1634 Note enums are treated as 32bit integers. 1635 1636 1637 @param key: A B{C{GQuark}} key. I{(int)} 1638 @param value: Pointer to the enum to update. I{(int)} 1639 @return: B{C{True}} if B{C{v}} was actually updated, B{C{False}} when there is no 1640 such enum in the container. 1641 1642 """ 1643 return None
1644 - def set_int64( key , value ):
1645 """ 1646 Stores a 64bit integer into B{C{container}}, identified by B{C{key}}. 1647 1648 @param key: A B{C{GQuark}} key. I{(int)} 1649 @param value: A 64bit integer. I{(gint64)} 1650 @return: 1651 """ 1652 return None
1653 - def get_int64( key ):
1654 """ 1655 Returns the 64bit integer in B{C{container}} identified by B{C{key}}. 1656 1657 1658 @param key: A B{C{GQuark}} key. I{(int)} 1659 @return: The 64bit integer as B{C{guint64}}. 1660 1661 """ 1662 return None
1663 - def UNIMPLEMENTED_gis_int64( key , value ):
1664 """ 1665 Get-if-set a 64bit integer from a container. 1666 1667 1668 @param key: A B{C{GQuark}} key. I{(int)} 1669 @param value: Pointer to the 64bit integer to update. I{(int)} 1670 @return: B{C{True}} if B{C{v}} was actually updated, B{C{False}} when there is no 1671 such 64bit integer in the container. 1672 1673 """ 1674 return None
1675 - def set_double( key , value ):
1676 """ 1677 Stores a double into B{C{container}}, identified by B{C{key}}. 1678 1679 @param key: A B{C{GQuark}} key. I{(int)} 1680 @param value: A double. I{(float)} 1681 @return: 1682 """ 1683 return None
1684 - def get_double( key ):
1685 """ 1686 Returns the double in B{C{container}} identified by B{C{key}}. 1687 1688 1689 @param key: A B{C{GQuark}} key. I{(int)} 1690 @return: The double as B{C{gdouble}}. 1691 1692 """ 1693 return None
1694 - def UNIMPLEMENTED_gis_double( key , value ):
1695 """ 1696 Get-if-set a double from a container. 1697 1698 1699 @param key: A B{C{GQuark}} key. I{(int)} 1700 @param value: Pointer to the double to update. I{(float)} 1701 @return: B{C{True}} if B{C{v}} was actually updated, B{C{False}} when there is no 1702 such double in the container. 1703 1704 """ 1705 return None
1706 - def set_string( key , value ):
1707 """ 1708 Set string for key to given value 1709 1710 1711 @param value: new string I{(string)} 1712 @return: 1713 """ 1714 return None
1715 - def set_const_string( key , value ):
1716 """ 1717 Stores a string into B{C{container}}, identified by B{C{key}}. 1718 1719 The container makes a copy of the string, so it can be used on static 1720 strings. 1721 1722 Since: 2.38 1723 1724 @param key: A B{C{GQuark}} key. I{(int)} 1725 @param value: A nul-terminated string. I{(string)} 1726 @return: 1727 """ 1728 return None
1729 - def get_string( key ):
1730 """ 1731 Returns the string in B{C{container}} identified by B{C{key}}. 1732 1733 The returned string must be treated as constant and never freed or modified. 1734 1735 1736 @param key: A B{C{GQuark}} key. I{(int)} 1737 @return: The string. 1738 1739 """ 1740 return None
1741 - def UNIMPLEMENTED_gis_string( key , value ):
1742 """ 1743 Get-if-set a string from a container. 1744 1745 The string eventually stored in B{C{value}} must be treated as constant and 1746 never freed or modified. 1747 1748 1749 @param key: A B{C{GQuark}} key. I{(int)} 1750 @param value: Pointer to the string pointer to update. I{(const-guchar**)} 1751 @return: B{C{True}} if B{C{v}} was actually updated, B{C{False}} when there is no 1752 such string in the container. 1753 1754 """ 1755 return None
1756 - def set_object( key , value ):
1757 """ 1758 Stores an object into B{C{container}}, identified by B{C{key}}. 1759 1760 The container claims ownership on the object, i.e. its reference count is 1761 incremented. 1762 1763 The object must implement B{C{Serializable}} interface to allow serialization 1764 of the container. 1765 1766 @param key: A B{C{GQuark}} key. I{(int)} 1767 @param value: An object to store into container. I{(gpointer)} 1768 @return: 1769 """ 1770 return None
1771 - def get_object( key ):
1772 """ 1773 Get object of given key from container. 1774 1775 1776 @return: object of given key 1777 1778 """ 1779 return None
1780 - def gis_object( key , value ):
1781 """ 1782 Get-if-set an object from a container. 1783 1784 The object eventually stored in B{C{value}} doesn't have its reference count 1785 increased, use g_object_ref() if you want to access it even when 1786 B{C{container}} may cease to exist. 1787 1788 1789 @param key: A B{C{GQuark}} key. I{(int)} 1790 @param value: Pointer to the object pointer to update. I{(gpointer)} 1791 @return: B{C{True}} if B{C{v}} was actually updated, B{C{False}} when there is no 1792 such object in the container. 1793 1794 """ 1795 return None
1797 """ 1798 Creates a text representation of B{C{container}} contents. 1799 1800 Note only simple data types are supported as serialization of compound 1801 objects is not controllable. 1802 1803 1804 @return: A pointer array, each item containing string with one container 1805 item representation (name, type, value). The array is sorted by name. 1806 1807 """ 1808 return None
1809 - def contains_by_name( name ):
1810 """ 1811 Expands to B{C{True}} if container B{C{c}} contains a value identified by name B{C{n}}. 1812 1813 @param n: A nul-terminated name (id). 1814 @return: 1815 """ 1816 return None
1817 - def remove_by_name( name ):
1818 """ 1819 Removes a value identified by name B{C{n}} from container B{C{c}}. 1820 1821 Expands to B{C{True}} if there was such a value and was removed. 1822 1823 @param n: A nul-terminated name (id). 1824 @return: 1825 """ 1826 return None
1827 - def rename_by_name( name , new_name , delete ):
1828 """ 1829 Makes a value in container B{C{c}} identified by name B{C{n}} to be identified by 1830 new name B{C{nn}}. 1831 1832 See L{Container.rename}() for details. 1833 1834 @param n: A nul-terminated name (id). 1835 @param nn: A nul-terminated name (id). 1836 @param f: Whether to delete existing value at B{C{newkey}}. 1837 @return: 1838 """ 1839 return None
1840 - def set_boolean_by_name( name , value ):
1841 """ 1842 Stores a boolean into container B{C{c}}, identified by name B{C{n}}. 1843 1844 @param n: A nul-terminated name (id). 1845 @param v: A boolean. 1846 @return: 1847 """ 1848 return None
1849 - def set_double_by_name( name , value ):
1850 """ 1851 Stores a double into container B{C{c}}, identified by name B{C{n}}. 1852 1853 @param n: A nul-terminated name (id). 1854 @param v: A double integer. 1855 @return: 1856 """ 1857 return None
1858 - def set_enum_by_name( name , value ):
1859 """ 1860 Stores an enum into container B{C{c}}, identified by name B{C{n}}. 1861 1862 Note enums are treated as 32bit integers. 1863 1864 @param n: A nul-terminated name (id). 1865 @param v: An enum. 1866 @return: 1867 """ 1868 return None
1869 - def set_int32_by_name( name , value ):
1870 """ 1871 Stores a 32bit integer into container B{C{c}}, identified by name B{C{n}}. 1872 1873 @param n: A nul-terminated name (id). 1874 @param v: A 32bit integer. 1875 @return: 1876 """ 1877 return None
1878 - def set_int64_by_name( name , value ):
1879 """ 1880 Stores a 64bit integer into container B{C{c}}, identified by name B{C{n}}. 1881 1882 @param n: A nul-terminated name (id). 1883 @param v: A 64bit integer. 1884 @return: 1885 """ 1886 return None
1887 - def set_object_by_name( name , value ):
1888 """ 1889 Stores an object into container B{C{c}}, identified by name B{C{n}}. 1890 1891 See L{Container.set_object}() for details. 1892 1893 @param n: A nul-terminated name (id). 1894 @param v: An object to store into container. 1895 @return: 1896 """ 1897 return None
1898 - def set_uchar_by_name( name , value ):
1899 """ 1900 Stores an unsigned character into container B{C{c}}, identified by name B{C{n}}. 1901 1902 @param n: A nul-terminated name (id). 1903 @param v: An unsigned character. 1904 @return: 1905 """ 1906 return None
1907 - def set_string_by_name( name , value ):
1908 """ 1909 Stores a string into container B{C{c}}, identified by name B{C{n}}. 1910 1911 The container takes ownership of the string, so it can't be used on 1912 static strings, use g_strdup() to duplicate them first. 1913 1914 @param n: A nul-terminated name (id). 1915 @param v: A nul-terminated string. 1916 @return: 1917 """ 1918 return None
1919 - def get_boolean_by_name( name ):
1920 """ 1921 Gets the boolean in container B{C{c}} identified by name B{C{n}}. 1922 1923 @param n: A nul-terminated name (id). 1924 @return: 1925 """ 1926 return None
1927 - def get_double_by_name( name ):
1928 """ 1929 Gets the double in container B{C{c}} identified by name B{C{n}}. 1930 1931 @param n: A nul-terminated name (id). 1932 @return: 1933 """ 1934 return None
1935 - def get_enum_by_name( name ):
1936 """ 1937 Gets the enum in container B{C{c}} identified by name B{C{n}}. 1938 1939 Note enums are treated as 32bit integers. 1940 1941 @param n: A nul-terminated name (id). 1942 @return: 1943 """ 1944 return None
1945 - def get_int32_by_name( name ):
1946 """ 1947 Gets the 32bit integer in container B{C{c}} identified by name B{C{n}}. 1948 1949 @param n: A nul-terminated name (id). 1950 @return: 1951 """ 1952 return None
1953 - def get_int64_by_name( name ):
1954 """ 1955 Gets the 64bit integer in container B{C{c}} identified by name B{C{n}}. 1956 1957 @param n: A nul-terminated name (id). 1958 @return: 1959 """ 1960 return None
1961 - def get_object_by_name( name ):
1962 """ 1963 Gets the object in container B{C{c}} identified by name B{C{n}}. 1964 1965 The returned object doesn't have its reference count increased, use 1966 g_object_ref() if you want to access it even when B{C{container}} may cease 1967 to exist. 1968 1969 @param n: A nul-terminated name (id). 1970 @return: 1971 """ 1972 return None
1973 - def get_uchar_by_name( name ):
1974 """ 1975 Gets the unsigned character in container B{C{c}} identified by name B{C{n}}. 1976 1977 @param n: A nul-terminated name (id). 1978 @return: 1979 """ 1980 return None
1981 - def get_value_by_name( name ):
1982 """ 1983 Gets the value in container B{C{c}} identified by name B{C{n}}. 1984 1985 @param n: A nul-terminated name (id). 1986 @return: 1987 """ 1988 return None
1989 - def get_string_by_name( name ):
1990 """ 1991 Gets the string in container B{C{c}} identified by name B{C{n}}. 1992 1993 The returned string must be treated as constant and never freed or modified. 1994 1995 @param n: A nul-terminated name (id). 1996 @return: 1997 """ 1998 return None
1999 - def get_object( key ):
2000 """ 2001 Get object of given key from container. 2002 2003 2004 @return: object of given key 2005 2006 """ 2007 return None
2008 - def set_string( key , value ):
2009 """ 2010 Set string for key to given value 2011 2012 2013 @param value: new string I{(some_type)} 2014 @return: 2015 """ 2016 return None
2017 -class Curve:
2018 - def __init__( ):
2019 """ 2020 Creates B{C{Curve}} widget. By default, the widget will have 3 curves. 2021 2022 2023 @return: new B{C{Curve}} widget. 2024 2025 """ 2026 return None
2027 - def reset( ):
2028 """ 2029 Removes all control points, resetting the curves to their initial state. 2030 2031 2032 @return: 2033 """ 2034 return None
2035 - def set_range( min_x , max_x , min_y , max_y ):
2036 return None
2037 - def set_curve_type( type ):
2038 return None
2039 - def set_channels( num_channels , colors ):
2040 return None
2041 - def UNIMPLEMENTED_set_control_points( channel_data , prune ):
2042 return None
2043 - def UNIMPLEMENTED_get_control_points( channel_data , triplets ):
2044 return None
2045 -class DataField:
2046 - def __init__( xres , yres , xreal , yreal , nullme ):
2047 """ 2048 Creates a new data field. 2049 2050 2051 @param yres: Y-resolution, i.e., the number of rows. I{(int)} 2052 @param xreal: Real horizontal physical dimension. I{(float)} 2053 @param yreal: Real vertical physical dimension. I{(float)} 2054 @param nullme: Whether the data field should be initialized to zeroes. If B{C{False}}, 2055 the data will not be initialized. I{(bool)} 2056 @return: A newly created data field. 2057 2058 """ 2059 return None
2060 - def sum_fields( operand1 , operand2 ):
2061 """ 2062 Sums two data fields. 2063 2064 @param operand1: First data field operand. I{(L{DataField})} 2065 @param operand2: Second data field operand. I{(L{DataField})} 2066 @return: 2067 """ 2068 return None
2069 - def subtract_fields( operand1 , operand2 ):
2070 """ 2071 Subtracts one data field from another. 2072 2073 @param operand1: First data field operand. I{(L{DataField})} 2074 @param operand2: Second data field operand. I{(L{DataField})} 2075 @return: 2076 """ 2077 return None
2078 - def divide_fields( operand1 , operand2 ):
2079 """ 2080 Divides one data field with another. 2081 2082 @param operand1: First data field operand. I{(L{DataField})} 2083 @param operand2: Second data field operand. I{(L{DataField})} 2084 @return: 2085 """ 2086 return None
2087 - def multiply_fields( operand1 , operand2 ):
2088 """ 2089 Multiplies two data fields. 2090 2091 @param operand1: First data field operand. I{(L{DataField})} 2092 @param operand2: Second data field operand. I{(L{DataField})} 2093 @return: 2094 """ 2095 return None
2096 - def min_of_fields( operand1 , operand2 ):
2097 """ 2098 Finds point-wise maxima of two data fields. 2099 2100 @param operand1: First data field operand. I{(L{DataField})} 2101 @param operand2: Second data field operand. I{(L{DataField})} 2102 @return: 2103 """ 2104 return None
2105 - def max_of_fields( operand1 , operand2 ):
2106 """ 2107 Finds point-wise minima of two data fields. 2108 2109 @param operand1: First data field operand. I{(L{DataField})} 2110 @param operand2: Second data field operand. I{(L{DataField})} 2111 @return: 2112 """ 2113 return None
2114 - def hypot_of_fields( operand1 , operand2 ):
2115 """ 2116 Finds point-wise hypotenuse of two data fields. 2117 2118 Since: 2.31 2119 2120 @param operand1: First data field operand. I{(L{DataField})} 2121 @param operand2: Second data field operand. I{(L{DataField})} 2122 @return: 2123 """ 2124 return None
2125 - def check_compatibility( data_field2 , check ):
2126 """ 2127 Checks whether two data fields are compatible. 2128 2129 2130 @param data_field2: Another data field. I{(L{DataField})} 2131 @param check: The compatibility tests to perform. I{(DataCompatibilityFlags)} 2132 @return: Zero if all tested properties are compatible. Flags corresponding 2133 to failed tests if data fields are not compatible. 2134 2135 """ 2136 return None
2137 - def extend( left , right , up , down , exterior , fill_value , keep_offsets ):
2138 """ 2139 Creates a new data field by extending another data field using the specified 2140 method of exterior handling. 2141 2142 Since: 2.36 2143 2144 @param left: Number of pixels to extend to the left (towards lower column indices). I{(int)} 2145 @param right: Number of pixels to extend to the right (towards higher column 2146 indices). I{(int)} 2147 @param up: Number of pixels to extend up (towards lower row indices). I{(int)} 2148 @param down: Number of pixels to extend down (towards higher row indices). I{(int)} 2149 @param exterior: Exterior pixels handling. I{(ExteriorType)} 2150 @param fill_value: The value to use with B{C{EXTERIOR_FIXED_VALUE}} exterior. I{(float)} 2151 @param keep_offsets: B{C{True}} to set the X and Y offsets of the new field 2152 using B{C{field}} offsets. B{C{False}} to set offsets 2153 of the new field to zeroes. I{(bool)} 2154 @return: A newly created data field. 2155 2156 2157 """ 2158 return None
2159 - def correct_laplace_iteration( mask_field , buffer_field , corrfactor , error ):
2160 """ 2161 Performs one interation of Laplace data correction. 2162 2163 Tries to remove all the points in mask off the data by using 2164 iterative method similar to solving heat flux equation. 2165 2166 Use this function repeatedly until reasonable B{C{error}} is reached. 2167 2168 @param mask_field: Mask of places to be corrected. I{(L{DataField})} 2169 @param buffer_field: Initialized to same size as mask and data. I{(L{DataField})} 2170 @param error: Maximum change within last step. I{(float)} 2171 @param corrfactor: Correction factor within step. I{(float)} 2172 @return: 2173 """ 2174 return None
2175 - def correct_average( mask_field ):
2176 """ 2177 Fills data under mask with the average value. 2178 2179 This function simply puts average value of all the B{C{data_field}} values (both 2180 masked and unmasked) into points in B{C{data_field}} lying under points where 2181 B{C{mask_field}} values are nonzero. 2182 2183 In most cases you probably want to use 2184 L{DataField.correct_average_unmasked}() instead. 2185 2186 @param mask_field: Mask of places to be corrected. I{(L{DataField})} 2187 @return: 2188 """ 2189 return None
2190 - def correct_average_unmasked( mask_field ):
2191 """ 2192 Fills data under mask with the average value of unmasked data. 2193 2194 This function calculates the average value of all unmasked pixels in 2195 B{C{data_field}} and then fills all the masked pixels with this average value. 2196 It is useful as the first rough step of correction of data under the mask. 2197 2198 If all data are masked the field is filled with zeroes. 2199 2200 Since: 2.44 2201 2202 @param mask_field: Mask of places to be corrected. I{(L{DataField})} 2203 @return: 2204 """ 2205 return None
2206 - def mask_outliers( mask_field , thresh ):
2207 """ 2208 Creates mask of data that are above or below B{C{thresh}}*sigma from average 2209 height. 2210 2211 Sigma denotes root-mean square deviation of heights. This criterium 2212 corresponds to the usual Gaussian distribution outliers detection if 2213 B{C{thresh}} is 3. 2214 2215 @param mask_field: A data field to be filled with mask. I{(L{DataField})} 2216 @param thresh: Threshold value. I{(float)} 2217 @return: 2218 """ 2219 return None
2220 - def mask_outliers2( mask_field , thresh_low , thresh_high ):
2221 """ 2222 Creates mask of data that are above or below multiples of rms from average 2223 height. 2224 2225 Data that are below B{C{mean}}-B{C{thresh_low}}*B{C{sigma}} or above 2226 B{C{mean}}+B{C{thresh_high}}*B{C{sigma}} are marked as outliers, where B{C{sigma}} denotes the 2227 root-mean square deviation of heights. 2228 2229 Since: 2.26 2230 2231 @param mask_field: A data field to be filled with mask. I{(L{DataField})} 2232 @param thresh_low: Lower threshold value. I{(float)} 2233 @param thresh_high: Upper threshold value. I{(float)} 2234 @return: 2235 """ 2236 return None
2237 - def UNIMPLEMENTED_distort( dest , invtrans , user_data , interp , exterior , fill_value ):
2238 """ 2239 Distorts a data field in the horizontal plane. 2240 2241 Note the transform function B{C{invtrans}} is the inverse transform, in other 2242 words it calculates the old coordinates from the new coordinates (the 2243 transform would not be uniquely defined the other way round). 2244 2245 Since: 2.5 2246 2247 @param dest: Destination data field. I{(L{DataField})} 2248 @param invtrans: Inverse transform function, that is the transformation from 2249 new coordinates to old coordinates. It gets 2250 (B{C{j}}+0.5, B{C{i}}+0.5), where B{C{i}} and B{C{j}} are the new row and column 2251 indices, passed as the input coordinates. The output coordinates 2252 should follow the same convention. Unless a special exterior 2253 handling is required, the transform function does not need to 2254 concern itself with coordinates being outside of the data. I{(CoordTransform2DFunc)} 2255 @param user_data: Pointer passed as B{C{user_data}} to B{C{invtrans}}. I{(gpointer)} 2256 @param interp: Interpolation type to use. I{(InterpolationType)} 2257 @param exterior: Exterior pixels handling. I{(ExteriorType)} 2258 @param fill_value: The value to use with B{C{EXTERIOR_FIXED_VALUE}}. I{(float)} 2259 @return: 2260 """ 2261 return None
2262 - def UNIMPLEMENTED_sample_distorted( dest , coords , interp , exterior , fill_value ):
2263 """ 2264 Resamples a data field in an arbitrarily distorted manner. 2265 2266 Each item in B{C{coords}} corresponds to one pixel in B{C{dest}} and gives the 2267 coordinates in B{C{source}} defining the value to set in this pixel. 2268 2269 Since: 2.45 2270 2271 @param dest: Destination data field. I{(L{DataField})} 2272 @param coords: Array of B{C{source}} coordinates with the same number of items as 2273 B{C{dest}}, ordered as data field data. 2274 See L{DataField.distort}() for coordinate convention discussion. I{(const-XY*)} 2275 @param interp: Interpolation type to use. I{(InterpolationType)} 2276 @param exterior: Exterior pixels handling. I{(ExteriorType)} 2277 @param fill_value: The value to use with B{C{EXTERIOR_FIXED_VALUE}}. I{(float)} 2278 @return: 2279 """ 2280 return None
2281 - def affine( dest , invtrans , interp , exterior , fill_value ):
2282 """ 2283 Performs an affine transformation of a data field in the horizontal plane. 2284 2285 Note the transform B{C{invtrans}} is the inverse transform, in other 2286 words it calculates the old coordinates from the new coordinates. This 2287 way even degenerate (non-invertible) transforms can be meaningfully used. 2288 Also note that the (column, row) coordinate system is left-handed. 2289 2290 Since: 2.34 2291 2292 @param dest: Destination data field. I{(L{DataField})} 2293 @param invtrans: Inverse transform, that is the transformation from 2294 new pixel coordinates to old pixel coordinates, represented as 2295 (B{C{j}}+0.5, B{C{i}}+0.5), where B{C{i}} and B{C{j}} are the row and column 2296 indices. It is represented as a six-element array [B{C{axx}}, B{C{axy}}, 2297 B{C{ayx}}, B{C{ayy}}, B{C{bx}}, B{C{by}}] where B{C{axy}} is the coefficient from B{C{x}} to 2298 B{C{y}}. I{(const-gdouble*)} 2299 @param interp: Interpolation type to use. I{(InterpolationType)} 2300 @param exterior: Exterior pixels handling. I{(ExteriorType)} 2301 @param fill_value: The value to use with B{C{EXTERIOR_FIXED_VALUE}}. I{(float)} 2302 @return: 2303 """ 2304 return None
2305 - def get_correlation_score( kernel_field , col , row , kernel_col , kernel_row , kernel_width , kernel_height ):
2306 """ 2307 Calculates a correlation score in one point. 2308 2309 Correlation window size is given 2310 by B{C{kernel_col}}, B{C{kernel_row}}, B{C{kernel_width}}, B{C{kernel_height}}, 2311 postion of the correlation window on data is given by 2312 B{C{col}}, B{C{row}}. 2313 2314 If anything fails (data too close to boundary, etc.), 2315 function returns -1.0 (none correlation).. 2316 2317 2318 @param kernel_field: Kernel to correlate data field with. I{(L{DataField})} 2319 @param col: Upper-left column position in the data field. I{(int)} 2320 @param row: Upper-left row position in the data field. I{(int)} 2321 @param kernel_col: Upper-left column position in kernel field. I{(int)} 2322 @param kernel_row: Upper-left row position in kernel field. I{(int)} 2323 @param kernel_width: Width of kernel field area. I{(int)} 2324 @param kernel_height: Heigh of kernel field area. I{(int)} 2325 @return: Correlation score (between -1.0 and 1.0). Value 1.0 denotes 2326 maximum correlation, -1.0 none correlation. 2327 2328 """ 2329 return None
2330 - def get_weighted_correlation_score( kernel_field , weight_field , col , row , kernel_col , kernel_row , kernel_width , kernel_height ):
2331 """ 2332 Calculates a correlation score in one point using weights to center 2333 the used information to the center of kernel. 2334 2335 Correlation window size is given 2336 by B{C{kernel_col}}, B{C{kernel_row}}, B{C{kernel_width}}, B{C{kernel_height}}, 2337 postion of the correlation window on data is given by 2338 B{C{col}}, B{C{row}}. 2339 2340 If anything fails (data too close to boundary, etc.), 2341 function returns -1.0 (none correlation).. 2342 2343 2344 @param kernel_field: Kernel to correlate data field with. I{(L{DataField})} 2345 @param weight_field: data field of same size as kernel window size I{(L{DataField})} 2346 @param col: Upper-left column position in the data field. I{(int)} 2347 @param row: Upper-left row position in the data field. I{(int)} 2348 @param kernel_col: Upper-left column position in kernel field. I{(int)} 2349 @param kernel_row: Upper-left row position in kernel field. I{(int)} 2350 @param kernel_width: Width of kernel field area. I{(int)} 2351 @param kernel_height: Heigh of kernel field area. I{(int)} 2352 @return: Correlation score (between -1.0 and 1.0). Value 1.0 denotes 2353 maximum correlation, -1.0 none correlation. 2354 2355 """ 2356 return None
2357 - def crosscorrelate( data_field2 , x_dist , y_dist , score , search_width , search_height , window_width , window_height ):
2358 """ 2359 Algorithm for matching two different images of the same object under changes. 2360 2361 It does not use any special features 2362 for matching. It simply searches for all points (with their neighbourhood) 2363 of B{C{data_field1}} within B{C{data_field2}}. Parameters B{C{search_width}} and 2364 B{C{search_height}} 2365 determine maimum area where to search for points. The area is cenetered 2366 in the B{C{data_field2}} at former position of points at B{C{data_field1}}. 2367 2368 @param data_field2: A data field. I{(L{DataField})} 2369 @param x_dist: A data field to store x-distances to. I{(L{DataField})} 2370 @param y_dist: A data field to store y-distances to. I{(L{DataField})} 2371 @param score: Data field to store correlation scores to. I{(L{DataField})} 2372 @param search_width: Search area width. I{(int)} 2373 @param search_height: Search area height. I{(int)} 2374 @param window_width: Correlation window width. This parameter is not actually 2375 used. Pass zero. I{(int)} 2376 @param window_height: Correlation window height. This parameter is not actually 2377 used. Pass zero. I{(int)} 2378 @return: 2379 """ 2380 return None
2381 - def UNIMPLEMENTED_crosscorrelate_init( data_field2 , x_dist , y_dist , score , search_width , search_height , window_width , window_height ):
2382 """ 2383 Initializes a cross-correlation iterator. 2384 2385 This iterator reports its state as B{C{ComputationStateType}}. 2386 2387 2388 @param data_field2: A data field. I{(L{DataField})} 2389 @param x_dist: A data field to store x-distances to, or B{C{NULL}}. I{(L{DataField})} 2390 @param y_dist: A data field to store y-distances to, or B{C{NULL}}. I{(L{DataField})} 2391 @param score: Data field to store correlation scores to, or B{C{NULL}}. I{(L{DataField})} 2392 @param search_width: Search area width. I{(int)} 2393 @param search_height: Search area height. I{(int)} 2394 @param window_width: Correlation window width. I{(int)} 2395 @param window_height: Correlation window height. I{(int)} 2396 @return: A new cross-correlation iterator. 2397 2398 """ 2399 return None
2400 - def correlate( kernel_field , score , method ):
2401 """ 2402 Computes correlation score for all positions in a data field. 2403 2404 Correlation score is compute for all points in data field B{C{data_field}} 2405 and full size of correlation kernel B{C{kernel_field}}. 2406 2407 The points in B{C{score}} correspond to centers of kernel. More precisely, the 2408 point ((B{C{kxres}}-1)/2, (B{C{kyres}}-1)/2) in B{C{score}} corresponds to kernel field 2409 top left corner coincident with data field top left corner. Points outside 2410 the area where the kernel field fits into the data field completely are 2411 set to -1 for B{C{CORRELATION_NORMAL}}. 2412 2413 @param kernel_field: Correlation kernel. I{(L{DataField})} 2414 @param score: Data field to store correlation scores to. I{(L{DataField})} 2415 @param method: Correlation score calculation method. I{(CorrelationType)} 2416 @return: 2417 """ 2418 return None
2419 - def UNIMPLEMENTED_correlate_init( kernel_field , score ):
2420 """ 2421 Creates a new correlation iterator. 2422 2423 This iterator reports its state as B{C{ComputationStateType}}. 2424 2425 2426 @param kernel_field: Kernel to correlate data field with. I{(L{DataField})} 2427 @param score: Data field to store correlation scores to. I{(L{DataField})} 2428 @return: A new correlation iterator. 2429 2430 """ 2431 return None
2432 - def invalidate( ):
2433 """ 2434 Invalidates cached data field stats. 2435 2436 User code should rarely need this macro, as all B{C{DataField}} methods do 2437 proper invalidation when they change data, as well as 2438 L{DataField.get_data}() does. 2439 2440 However, if you get raw data with L{DataField.get_data}() and then mix 2441 direct changes to it with calls to methods like L{DataField.get_max}(), 2442 you may need to explicitely invalidate cached values to let 2443 L{DataField.get_max}() know it has to recompute the maximum. 2444 2445 @return: 2446 """ 2447 return None
2448 - def new_alike( nullme ):
2449 """ 2450 Creates a new data field similar to an existing one. 2451 2452 Use L{DataField.duplicate}() if you want to copy a data field including 2453 data. 2454 2455 2456 @param nullme: Whether the data field should be initialized to zeroes. If B{C{False}}, 2457 the data will not be initialized. I{(bool)} 2458 @return: A newly created data field. 2459 2460 """ 2461 return None
2462 - def data_changed( ):
2463 """ 2464 Emits signal "data-changed" on a data field. 2465 2466 @return: 2467 """ 2468 return None
2469 - def new_resampled( xres , yres , interpolation ):
2470 """ 2471 Creates a new data field by resampling an existing one. 2472 2473 This method is equivalent to L{DataField.duplicate}() followed by 2474 L{DataField.resample}(), but it is more efficient. 2475 2476 2477 @param xres: Desired X resolution. I{(int)} 2478 @param yres: Desired Y resolution. I{(int)} 2479 @param interpolation: Interpolation method to use. I{(InterpolationType)} 2480 @return: A newly created data field. 2481 2482 """ 2483 return None
2484 - def resample( xres , yres , interpolation ):
2485 """ 2486 Resamples a data field using given interpolation method 2487 2488 This method may invalidate raw data buffer returned by 2489 L{DataField.get_data}(). 2490 2491 @param xres: Desired X resolution. I{(int)} 2492 @param yres: Desired Y resolution. I{(int)} 2493 @param interpolation: Interpolation method to use. I{(InterpolationType)} 2494 @return: 2495 """ 2496 return None
2497 - def resize( ulcol , ulrow , brcol , brrow ):
2498 """ 2499 Resizes (crops) a data field. 2500 2501 Crops a data field to a rectangle between upper-left and bottom-right 2502 points, recomputing real size. 2503 2504 This method may invalidate raw data buffer returned by 2505 L{DataField.get_data}(). 2506 2507 @param ulcol: Upper-left column coordinate. I{(int)} 2508 @param ulrow: Upper-left row coordinate. I{(int)} 2509 @param brcol: Bottom-right column coordinate + 1. I{(int)} 2510 @param brrow: Bottom-right row coordinate + 1. I{(int)} 2511 @return: 2512 """ 2513 return None
2514 - def area_extract( col , row , width , height ):
2515 """ 2516 Extracts a rectangular part of a data field to a new data field. 2517 2518 2519 @param row: Upper-left row coordinate. I{(int)} 2520 @param col: Upper-left column coordinate. I{(int)} 2521 @param width: Area width (number of columns). I{(int)} 2522 @param height: Area height (number of rows). I{(int)} 2523 @return: The extracted area as a newly created data field. 2524 2525 """ 2526 return None
2527 - def copy( dest , nondata_too ):
2528 """ 2529 Copies the contents of an already allocated data field to a data field 2530 of the same size. 2531 2532 @param dest: Destination data field. I{(L{DataField})} 2533 @param nondata_too: Whether non-data (units) should be copied too. I{(bool)} 2534 @return: 2535 """ 2536 return None
2537 - def area_copy( dest , col , row , width , height , destcol , destrow ):
2538 """ 2539 Copies a rectangular area from one data field to another. 2540 2541 The area starts at (B{C{col}}, B{C{row}}) in B{C{src}} and its dimension is B{C{width}}*B{C{height}}. 2542 It is copied to B{C{dest}} starting from (B{C{destcol}}, B{C{destrow}}). 2543 2544 The source area has to be completely contained in B{C{src}}. No assumptions are 2545 made about destination position, however, parts of the source area sticking 2546 out the destination data field B{C{dest}} are cut off. 2547 2548 If B{C{src}} is equal to B{C{dest}}, the areas may not overlap. 2549 2550 @param dest: Destination data field. I{(L{DataField})} 2551 @param col: Area upper-left column coordinate in B{C{src}}. I{(int)} 2552 @param row: Area upper-left row coordinate B{C{src}}. I{(int)} 2553 @param width: Area width (number of columns), pass -1 for full B{C{src}} widdth. I{(int)} 2554 @param height: Area height (number of rows), pass -1 for full B{C{src}} height. I{(int)} 2555 @param destcol: Destination column in B{C{dest}}. I{(int)} 2556 @param destrow: Destination row in B{C{dest}}. I{(int)} 2557 @return: 2558 """ 2559 return None
2560 - def get_data( ):
2561 """ 2562 Create a tuple of data which the datafield contains. Content of the tuple is NOT reference to original datafield but its copy. 2563 2564 2565 @return: tuple of raw numeric data from DataField 2566 2567 """ 2568 return None
2569 - def get_xres( ):
2570 """ 2571 Gets X resolution (number of columns) of a data field. 2572 2573 2574 @return: X resolution. 2575 2576 """ 2577 return None
2578 - def get_yres( ):
2579 """ 2580 Gets Y resolution (number of rows) of the field. 2581 2582 2583 @return: Y resolution. 2584 2585 """ 2586 return None
2587 - def get_xreal( ):
2588 """ 2589 Gets the X real (physical) size of a data field. 2590 2591 2592 @return: X real size value. 2593 2594 """ 2595 return None
2596 - def get_yreal( ):
2597 """ 2598 Gets the Y real (physical) size of a data field. 2599 2600 2601 @return: Y real size value. 2602 2603 """ 2604 return None
2605 - def set_xreal( xreal ):
2606 """ 2607 Sets X real (physical) size value of a data field. 2608 2609 @param xreal: New X real size value. I{(float)} 2610 @return: 2611 """ 2612 return None
2613 - def set_yreal( yreal ):
2614 """ 2615 Sets Y real (physical) size value of a data field. 2616 2617 @param yreal: New Y real size value. I{(float)} 2618 @return: 2619 """ 2620 return None
2621 - def get_xoffset( ):
2622 """ 2623 Gets the X offset of data field origin. 2624 2625 2626 @return: X offset value. 2627 2628 """ 2629 return None
2630 - def get_yoffset( ):
2631 """ 2632 Gets the Y offset of data field origin. 2633 2634 2635 @return: Y offset value. 2636 2637 """ 2638 return None
2639 - def set_xoffset( xoff ):
2640 """ 2641 Sets the X offset of a data field origin. 2642 2643 Note offsets don't affect any calculation, nor functions like 2644 L{DataField.rtoj}(). 2645 2646 @param xoff: New X offset value. I{(float)} 2647 @return: 2648 """ 2649 return None
2650 - def set_yoffset( yoff ):
2651 """ 2652 Sets the Y offset of a data field origin. 2653 2654 Note offsets don't affect any calculation, nor functions like 2655 L{DataField.rtoi}(). 2656 2657 @param yoff: New Y offset value. I{(float)} 2658 @return: 2659 """ 2660 return None
2661 - def get_si_unit_xy( ):
2662 """ 2663 Returns lateral SI unit of a data field. 2664 2665 2666 @return: SI unit corresponding to the lateral (XY) dimensions of the data 2667 field. Its reference count is not incremented. 2668 2669 """ 2670 return None
2671 - def get_si_unit_z( ):
2672 """ 2673 Returns value SI unit of a data field. 2674 2675 2676 @return: SI unit corresponding to the "height" (Z) dimension of the data 2677 field. Its reference count is not incremented. 2678 2679 """ 2680 return None
2681 - def set_si_unit_xy( si_unit ):
2682 """ 2683 Sets the SI unit corresponding to the lateral (XY) dimensions of a data 2684 field. 2685 2686 It does not assume a reference on B{C{si_unit}}, instead it adds its own 2687 reference. 2688 2689 @param si_unit: SI unit to be set. I{(L{SIUnit})} 2690 @return: 2691 """ 2692 return None
2693 - def set_si_unit_z( si_unit ):
2694 """ 2695 Sets the SI unit corresponding to the "height" (Z) dimension of a data 2696 field. 2697 2698 It does not assume a reference on B{C{si_unit}}, instead it adds its own 2699 reference. 2700 2701 @param si_unit: SI unit to be set. I{(L{SIUnit})} 2702 @return: 2703 """ 2704 return None
2705 - def UNIMPLEMENTED_get_value_format_xy( style , format ):
2706 """ 2707 Finds value format good for displaying coordinates of a data field. 2708 2709 2710 @param style: Unit format style. I{(SIUnitFormatStyle)} 2711 @param format: A SI value format to modify, or B{C{NULL}} to allocate a new one. I{(SIValueFormat*)} 2712 @return: The value format. If B{C{format}} is B{C{NULL}}, a newly allocated format 2713 is returned, otherwise (modified) B{C{format}} itself is returned. 2714 2715 """ 2716 return None
2717 - def UNIMPLEMENTED_get_value_format_z( style , format ):
2718 """ 2719 Finds value format good for displaying values of a data field. 2720 2721 2722 @param style: Unit format style. I{(SIUnitFormatStyle)} 2723 @param format: A SI value format to modify, or B{C{NULL}} to allocate a new one. I{(SIValueFormat*)} 2724 @return: The value format. If B{C{format}} is B{C{NULL}}, a newly allocated format 2725 is returned, otherwise (modified) B{C{format}} itself is returned. 2726 2727 """ 2728 return None
2729 - def copy_units_to_data_line( data_line ):
2730 """ 2731 Sets lateral and value units of a data line to match a data field. 2732 2733 @param data_line: A data line to set units of. I{(L{DataLine})} 2734 @return: 2735 """ 2736 return None
2737 - def itor( row ):
2738 """ 2739 Transforms vertical pixel coordinate to real (physical) Y coordinate. 2740 2741 That is it maps range [0..y-resolution] to range [0..real-y-size]. 2742 It is not suitable for conversion of matrix indices to physical coordinates, 2743 you have to use L{DataField.itor}(B{C{data_field}}, B{C{row}} + 0.5) for that. 2744 2745 2746 @param row: Vertical pixel coordinate. I{(float)} 2747 @return: Real Y coordinate. 2748 2749 """ 2750 return None
2751 - def jtor( col ):
2752 """ 2753 Transforms horizontal pixel coordinate to real (physical) X coordinate. 2754 2755 That is it maps range [0..x-resolution] to range [0..real-x-size]. 2756 It is not suitable for conversion of matrix indices to physical coordinates, 2757 you have to use L{DataField.jtor}(B{C{data_field}}, B{C{col}} + 0.5) for that. 2758 2759 2760 @param col: Horizontal pixel coordinate. I{(float)} 2761 @return: Real X coordinate. 2762 2763 """ 2764 return None
2765 - def rtoi( realy ):
2766 """ 2767 Transforms real (physical) Y coordinate to row. 2768 2769 That is it maps range [0..real-y-size] to range [0..y-resolution]. 2770 2771 2772 @param realy: Real (physical) Y coordinate. I{(float)} 2773 @return: Vertical pixel coodinate. 2774 2775 """ 2776 return None
2777 - def rtoj( realx ):
2778 """ 2779 Transforms real (physical) X coordinate to column. 2780 2781 That is it maps range [0..real-x-size] to range [0..x-resolution]. 2782 2783 2784 @param realx: Real (physical) X coodinate. I{(float)} 2785 @return: Horizontal pixel coordinate. 2786 2787 """ 2788 return None
2789 - def get_val( col , row ):
2790 """ 2791 Gets value at given position in a data field. 2792 2793 Do not access data with this function inside inner loops, it's slow. 2794 Get the raw data buffer with L{DataField.get_data_const}() and access it 2795 directly instead. 2796 2797 2798 @param col: Column index. I{(int)} 2799 @param row: Row index. I{(int)} 2800 @return: Value at (B{C{col}}, B{C{row}}). 2801 2802 """ 2803 return None
2804 - def set_val( col , row , value ):
2805 """ 2806 Sets value at given position in a data field. 2807 2808 Do not set data with this function inside inner loops, it's slow. Get the 2809 raw data buffer with L{DataField.get_data}() and write to it directly 2810 instead. 2811 2812 @param col: Column index. I{(int)} 2813 @param row: Row index. I{(int)} 2814 @param value: Value to set. I{(float)} 2815 @return: 2816 """ 2817 return None
2818 - def get_dval( x , y , interpolation ):
2819 """ 2820 Gets interpolated value at arbitrary data field point indexed by pixel 2821 coordinates. 2822 2823 Note pixel values are centered in pixels, so to get the same 2824 value as L{DataField.get_val}(B{C{data_field}}, B{C{j}}, B{C{i}}) returns, 2825 it's necessary to add 0.5: 2826 L{DataField.get_dval}(B{C{data_field}}, B{C{j}}+0.5, B{C{i}}+0.5, B{C{interpolation}}). 2827 2828 See also L{DataField.get_dval_real}() that does the same, but takes 2829 real coordinates. 2830 2831 2832 @param x: Horizontal position in pixel units, in range [0, x-resolution]. I{(float)} 2833 @param y: Vertical postition in pixel units, in range [0, y-resolution]. I{(float)} 2834 @param interpolation: Interpolation method to be used. I{(InterpolationType)} 2835 @return: Interpolated value at position (B{C{x}},B{C{y}}). 2836 2837 """ 2838 return None
2839 - def get_dval_real( x , y , interpolation ):
2840 """ 2841 Gets interpolated value at arbitrary data field point indexed by real 2842 coordinates. 2843 2844 See also L{DataField.get_dval}() that does the same, but takes pixel 2845 coordinates. 2846 2847 2848 @param x: X postion in real coordinates. I{(float)} 2849 @param y: Y postition in real coordinates. I{(float)} 2850 @param interpolation: Interpolation method to use. I{(InterpolationType)} 2851 @return: Value at position (B{C{x}},B{C{y}}). 2852 2853 """ 2854 return None
2855 - def rotate( angle , interpolation ):
2856 """ 2857 Rotates a data field by a given angle. 2858 2859 Values that get outside of data field by the rotation are lost. 2860 Undefined values from outside of data field that get inside are set to 2861 data field minimum value. 2862 2863 @param angle: Rotation angle (in radians). I{(float)} 2864 @param interpolation: Interpolation method to use. I{(InterpolationType)} 2865 @return: 2866 """ 2867 return None
2868 - def invert( x , y , z ):
2869 """ 2870 Reflects amd/or inverts a data field. 2871 2872 In the case of value reflection, it's inverted about the mean value. 2873 2874 @param x: B{C{True}} to reflect about X axis (i.e., vertically). I{(bool)} 2875 @param y: B{C{True}} to reflect about Y axis (i.e., horizontally). I{(bool)} 2876 @param z: B{C{True}} to invert in Z direction (i.e., invert values). I{(bool)} 2877 @return: 2878 """ 2879 return None
2880 - def fill( value ):
2881 """ 2882 Fills a data field with given value. 2883 2884 @param value: Value to be entered. I{(float)} 2885 @return: 2886 """ 2887 return None
2888 - def clear( ):
2889 """ 2890 Fills a data field with zeroes. 2891 2892 @return: 2893 """ 2894 return None
2895 - def multiply( value ):
2896 """ 2897 Multiplies all values in a data field by given value. 2898 2899 @param value: Value to multiply B{C{data_field}} with. I{(float)} 2900 @return: 2901 """ 2902 return None
2903 - def add( value ):
2904 """ 2905 Adds given value to all values in a data field. 2906 2907 @param value: Value to be added to data field values. I{(float)} 2908 @return: 2909 """ 2910 return None
2911 - def area_fill( col , row , width , height , value ):
2912 """ 2913 Fills a rectangular part of a data field with given value. 2914 2915 @param col: Upper-left column coordinate. I{(int)} 2916 @param row: Upper-left row coordinate. I{(int)} 2917 @param width: Area width (number of columns). I{(int)} 2918 @param height: Area height (number of rows). I{(int)} 2919 @param value: Value to be entered I{(float)} 2920 @return: 2921 """ 2922 return None
2923 - def area_fill_mask( mask , mode , col , row , width , height , value ):
2924 """ 2925 Fills a masked rectangular part of a data field with given value. 2926 2927 Since: 2.44 2928 2929 @param mask: Mask specifying which values to take into account/exclude, or B{C{NULL}}. I{(L{DataField})} 2930 @param mode: Masking mode to use. See the introduction for description of 2931 masking modes. I{(MaskingType)} 2932 @param col: Upper-left column coordinate. I{(int)} 2933 @param row: Upper-left row coordinate. I{(int)} 2934 @param width: Area width (number of columns). I{(int)} 2935 @param height: Area height (number of rows). I{(int)} 2936 @param value: Value to be entered I{(float)} 2937 @return: 2938 """ 2939 return None
2940 - def area_clear( col , row , width , height ):
2941 """ 2942 Fills a rectangular part of a data field with zeroes. 2943 2944 @param col: Upper-left column coordinate. I{(int)} 2945 @param row: Upper-left row coordinate. I{(int)} 2946 @param width: Area width (number of columns). I{(int)} 2947 @param height: Area height (number of rows). I{(int)} 2948 @return: 2949 """ 2950 return None
2951 - def area_multiply( col , row , width , height , value ):
2952 """ 2953 Multiplies values in a rectangular part of a data field by given value 2954 2955 @param col: Upper-left column coordinate. I{(int)} 2956 @param row: Upper-left row coordinate. I{(int)} 2957 @param width: Area width (number of columns). I{(int)} 2958 @param height: Area height (number of rows). I{(int)} 2959 @param value: Value to multiply area with. I{(float)} 2960 @return: 2961 """ 2962 return None
2963 - def area_add( col , row , width , height , value ):
2964 """ 2965 Adds given value to all values in a rectangular part of a data field. 2966 2967 @param col: Upper-left column coordinate. I{(int)} 2968 @param row: Upper-left row coordinate. I{(int)} 2969 @param width: Area width (number of columns). I{(int)} 2970 @param height: Area height (number of rows). I{(int)} 2971 @param value: Value to be added to area values. I{(float)} 2972 @return: 2973 """ 2974 return None
2975 - def get_profile( data_line , scol , srow , ecol , erow , res , thickness , interpolation ):
2976 """ 2977 Extracts a possibly averaged profile from data field to a data line. 2978 2979 2980 @param data_line: A data line. It will be resized to B{C{res}} samples. It is 2981 possible to pass B{C{NULL}} to instantiate and return a new 2982 B{C{DataLine}}. I{(L{DataLine})} 2983 @param scol: The column the line starts at (inclusive). I{(int)} 2984 @param srow: The row the line starts at (inclusive). I{(int)} 2985 @param ecol: The column the line ends at (inclusive). I{(int)} 2986 @param erow: The row the line ends at (inclusive). I{(int)} 2987 @param res: Requested resolution of data line (the number of samples to take). 2988 If nonpositive, data line resolution is chosen to match B{C{data_field}}'s. I{(int)} 2989 @param thickness: Thickness of line to be averaged. I{(int)} 2990 @param interpolation: Interpolation type to use. I{(InterpolationType)} 2991 @return: B{C{data_line}} itself if it was not B{C{NULL}}, otherwise a newly created 2992 data line. 2993 2994 """ 2995 return None
2996 - def get_row( data_line , row ):
2997 """ 2998 Extracts a data field row into a data line. 2999 3000 @param data_line: A data line. It will be resized to width ot B{C{data_field}}. I{(L{DataLine})} 3001 @param row: Row index. I{(int)} 3002 @return: 3003 """ 3004 return None
3005 - def get_column( data_line , col ):
3006 """ 3007 Extracts a data field column into a data line. 3008 3009 @param data_line: A data line. It will be resized to height of B{C{data_field}}. I{(L{DataLine})} 3010 @param col: Column index. I{(int)} 3011 @return: 3012 """ 3013 return None
3014 - def set_row( data_line , row ):
3015 """ 3016 Sets a row in the data field to values of a data line. 3017 3018 Data line length must be equal to width of data field. 3019 3020 @param data_line: A data line. I{(L{DataLine})} 3021 @param row: Row index. I{(int)} 3022 @return: 3023 """ 3024 return None
3025 - def set_column( data_line , col ):
3026 """ 3027 Sets a column in the data field to values of a data line. 3028 3029 Data line length must be equal to height of data field. 3030 3031 @param data_line: A data line. I{(L{DataLine})} 3032 @param col: Column index. I{(int)} 3033 @return: 3034 """ 3035 return None
3036 - def get_row_part( data_line , row , _from , to ):
3037 """ 3038 Extracts part of a data field row into a data line. 3039 3040 @param data_line: A data line. It will be resized to the row part width. I{(L{DataLine})} 3041 @param row: Row index. I{(int)} 3042 @param _from: Start column index. I{(int)} 3043 @param to: End column index + 1. I{(int)} 3044 @return: 3045 """ 3046 return None
3047 - def get_column_part( data_line , col , _from , to ):
3048 """ 3049 Extracts part of a data field column into a data line. 3050 3051 @param data_line: A data line. It will be resized to the column part height. I{(L{DataLine})} 3052 @param col: Column index. I{(int)} 3053 @param _from: Start row index. I{(int)} 3054 @param to: End row index + 1. I{(int)} 3055 @return: 3056 """ 3057 return None
3058 - def set_row_part( data_line , row , _from , to ):
3059 """ 3060 Puts a data line into a data field row. 3061 3062 If data line length differs from B{C{to}}-B{C{from}}, it is resampled to this length. 3063 3064 @param data_line: A data line. I{(L{DataLine})} 3065 @param row: Row index. I{(int)} 3066 @param _from: Start row index. I{(int)} 3067 @param to: End row index + 1. I{(int)} 3068 @return: 3069 """ 3070 return None
3071 - def set_column_part( data_line , col , _from , to ):
3072 """ 3073 Puts a data line into data field column. 3074 3075 If data line length differs from B{C{to}}-B{C{from}}, it is resampled to this length. 3076 3077 @param data_line: A data line. I{(L{DataLine})} 3078 @param col: Column index. I{(int)} 3079 @param _from: Start row index. I{(int)} 3080 @param to: End row index + 1. I{(int)} 3081 @return: 3082 """ 3083 return None
3084 - def get_xder( col , row ):
3085 """ 3086 Computes central derivative in X direction. 3087 3088 On border points, one-side derivative is returned. 3089 3090 3091 @param col: Column index. I{(int)} 3092 @param row: Row index. I{(int)} 3093 @return: Derivative in X direction. 3094 3095 """ 3096 return None
3097 - def get_yder( col , row ):
3098 """ 3099 Computes central derivative in Y direction. 3100 3101 On border points, one-side derivative is returned. 3102 3103 Note the derivative is for legacy reasons calulcated for the opposite 3104 y direction than is usual elsewhere in Gwyddion, i.e. if values increase 3105 with increasing row number, the returned value is negative. 3106 3107 3108 @param col: Column index. I{(int)} 3109 @param row: Row index. I{(int)} 3110 @return: Derivative in Y direction 3111 3112 """ 3113 return None
3114 - def get_angder( col , row , theta ):
3115 """ 3116 Computes derivative in direction specified by given angle. 3117 3118 3119 @param col: Column index. I{(int)} 3120 @param row: Row index. I{(int)} 3121 @param theta: Angle defining the direction (in radians, counterclockwise). I{(float)} 3122 @return: Derivative in direction given by angle B{C{theta}}. 3123 3124 """ 3125 return None
3126 - def UNIMPLEMENTED_average_xyz( density_map , points , npoints ):
3127 """ 3128 Fills a data field with regularised XYZ data using a simple method. 3129 3130 The real dimensions and offsets of B{C{field}} determine the rectangle in the XY 3131 plane that will be regularised. The regularisation method is fast but 3132 simple and there are no absolute guarantees of quality, even though the 3133 result will be usually quite acceptable. 3134 3135 This especially applies to reasonable views of the XYZ data. Unreasonable 3136 views can be rendered unreasonably. In particular if the rectangle does not 3137 contain any point from B{C{points}} (either due to high zoom to an empty region 3138 or by just being completely off) B{C{data_field}} will be filled entirely with 3139 the value of the closest point or something similar. 3140 3141 Since: 2.44 3142 3143 @param density_map: Optional data field to fill with XYZ point density map. It can 3144 be B{C{NULL}}. I{(L{DataField})} 3145 @param points: Array of XYZ points. Coordinates X and Y represent positions in 3146 the plane; the Z-coordinate represents values. I{(const-XYZ*)} 3147 @param npoints: Number of points. I{(int)} 3148 @return: 3149 """ 3150 return None
3151 - def xdwt( wt_coefs , direction , minsize ):
3152 """ 3153 Performs steps of the X-direction image wavelet decomposition. 3154 3155 The smallest low pass coefficients block is equal to B{C{minsize}}. Run with 3156 B{C{minsize}} = B{C{dfield}}->xres/2 to perform one step of decomposition 3157 or B{C{minsize}} = 4 to perform full decomposition (or anything between). 3158 3159 3160 @param wt_coefs: Data line where the wavelet transform coefficients are stored. I{(L{DataLine})} 3161 @param direction: Transform direction. I{(TransformDirection)} 3162 @param minsize: size of minimal transform result block I{(int)} 3163 @return: 3164 """ 3165 return None
3166 - def ydwt( wt_coefs , direction , minsize ):
3167 """ 3168 Performs steps of the Y-direction image wavelet decomposition. 3169 3170 The smallest low pass coefficients block is equal to B{C{minsize}}. Run with 3171 B{C{minsize}} = B{C{dfield}}->yres/2 to perform one step of decomposition 3172 or B{C{minsize}} = 4 to perform full decomposition (or anything between). 3173 3174 3175 @param wt_coefs: Data line where the wavelet transform coefficients are stored. I{(L{DataLine})} 3176 @param direction: Transform direction. I{(TransformDirection)} 3177 @param minsize: size of minimal transform result block I{(int)} 3178 @return: 3179 """ 3180 return None
3181 - def dwt( wt_coefs , direction , minsize ):
3182 """ 3183 Performs steps of the 2D image wavelet decomposition. 3184 3185 The smallest low pass coefficients block is equal to B{C{minsize}}. Run with 3186 B{C{minsize}} = B{C{dfield}}->xres/2 to perform one step of decomposition 3187 or B{C{minsize}} = 4 to perform full decomposition (or anything between). 3188 3189 3190 @param wt_coefs: Data line where the wavelet transform coefficients are stored. I{(L{DataLine})} 3191 @param direction: Transform direction. I{(TransformDirection)} 3192 @param minsize: size of minimal transform result block I{(int)} 3193 @return: 3194 """ 3195 return None
3196 - def dwt_mark_anisotropy( mask , wt_coefs , ratio , lowlimit ):
3197 return None
3198 - def elliptic_area_fill( col , row , width , height , value ):
3199 """ 3200 Fills an elliptic region of a data field with given value. 3201 3202 The elliptic region is defined by its bounding box which must be completely 3203 contained in the data field. 3204 3205 3206 @param col: Upper-left bounding box column coordinate. I{(int)} 3207 @param row: Upper-left bounding box row coordinate. I{(int)} 3208 @param width: Bounding box width (number of columns). I{(int)} 3209 @param height: Bounding box height (number of rows). I{(int)} 3210 @param value: Value to be entered. I{(float)} 3211 @return: The number of filled values. 3212 3213 """ 3214 return None
3215 - def elliptic_area_extract( col , row , width , height , data ):
3216 """ 3217 Extracts values from an elliptic region of a data field. 3218 3219 The elliptic region is defined by its bounding box which must be completely 3220 contained in the data field. 3221 3222 3223 @param col: Upper-left bounding box column coordinate. I{(int)} 3224 @param row: Upper-left bounding box row coordinate. I{(int)} 3225 @param width: Bounding box width (number of columns). I{(int)} 3226 @param height: Bounding box height (number of rows). I{(int)} 3227 @param data: Location to store the extracted values to. Its size has to be 3228 sufficient to contain all the extracted values. As a conservative 3229 estimate B{C{width}}*B{C{height}} can be used, or the 3230 size can be calculated with L{DataField.get_elliptic_area_size}(). I{(gdouble*)} 3231 @return: The number of extracted values. 3232 3233 """ 3234 return None
3235 - def elliptic_area_unextract( col , row , width , height , data ):
3236 """ 3237 Puts values back to an elliptic region of a data field. 3238 3239 The elliptic region is defined by its bounding box which must be completely 3240 contained in the data field. 3241 3242 This method does the reverse of L{DataField.elliptic_area_extract}() 3243 allowing to implement pixel-wise filters on elliptic areas. Values from 3244 B{C{data}} are put back to the same positions 3245 L{DataField.elliptic_area_extract}() took them from. 3246 3247 @param col: Upper-left bounding box column coordinate. I{(int)} 3248 @param row: Upper-left bounding box row coordinate. I{(int)} 3249 @param width: Bounding box width (number of columns). I{(int)} 3250 @param height: Bounding box height (number of rows). I{(int)} 3251 @param data: The values to put back. It must be the same array as in previous 3252 L{DataField.elliptic_area_extract}(). I{(const-gdouble*)} 3253 @return: 3254 """ 3255 return None
3256 - def circular_area_fill( col , row , radius , value ):
3257 """ 3258 Fills an elliptic region of a data field with given value. 3259 3260 3261 @param col: Row index of circular area centre. I{(int)} 3262 @param row: Column index of circular area centre. I{(int)} 3263 @param radius: Circular area radius (in pixels). Any value is allowed, although 3264 to get areas that do not deviate from true circles after 3265 pixelization too much, half-integer values are recommended, 3266 integer values are NOT recommended. I{(float)} 3267 @param value: Value to be entered. I{(float)} 3268 @return: The number of filled values. 3269 3270 """ 3271 return None
3272 - def circular_area_extract( col , row , radius , data ):
3273 """ 3274 Extracts values from a circular region of a data field. 3275 3276 3277 @param col: Row index of circular area centre. I{(int)} 3278 @param row: Column index of circular area centre. I{(int)} 3279 @param radius: Circular area radius (in pixels). See 3280 L{DataField.circular_area_extract_with_pos}() for caveats. I{(float)} 3281 @param data: Location to store the extracted values to. See 3282 L{DataField.circular_area_extract_with_pos}(). I{(gdouble*)} 3283 @return: The number of extracted values. It can be zero when the inside of 3284 the circle does not intersect with the data field. 3285 3286 """ 3287 return None
3288 - def UNIMPLEMENTED_circular_area_extract_with_pos( col , row , radius , data , xpos , ypos ):
3289 """ 3290 Extracts values with positions from a circular region of a data field. 3291 3292 The row and column indices stored to B{C{xpos}} and B{C{ypos}} are relative to the 3293 area centre, i.e. to (B{C{col}}, B{C{row}}). The central pixel will therefore have 3294 0 at the corresponding position in both B{C{xpos}} and B{C{ypos}}. 3295 3296 Since: 2.2 3297 3298 @param col: Row index of circular area centre. I{(int)} 3299 @param row: Column index of circular area centre. I{(int)} 3300 @param radius: Circular area radius (in pixels). Any value is allowed, although 3301 to get areas that do not deviate from true circles after 3302 pixelization too much, half-integer values are recommended, 3303 integer radii are NOT recommended. I{(float)} 3304 @param data: Location to store the extracted values to. Its size has to be 3305 sufficient to contain all the extracted values. As a conservative 3306 estimate (2*floor(B{C{radius}})+1)^2 can be used, or the size can be 3307 calculated with L{DataField.get_circular_area_size}(). I{(gdouble*)} 3308 @param xpos: Location to store relative column indices of values in B{C{data}} to, 3309 the size requirements are the same as for B{C{data}}. I{(int)} 3310 @param ypos: Location to store relative tow indices of values in B{C{data}} to, 3311 the size requirements are the same as for B{C{data}}. I{(int)} 3312 @return: The number of extracted values. It can be zero when the inside of 3313 the circle does not intersect with the data field. 3314 3315 3316 """ 3317 return None
3318 - def circular_area_unextract( col , row , radius , data ):
3319 """ 3320 Puts values back to a circular region of a data field. 3321 3322 This method does the reverse of L{DataField.circular_area_extract}() 3323 allowing to implement pixel-wise filters on circular areas. Values from 3324 B{C{data}} are put back to the same positions 3325 L{DataField.circular_area_extract}() took them from. 3326 3327 @param col: Row index of circular area centre. I{(int)} 3328 @param row: Column index of circular area centre. I{(int)} 3329 @param radius: Circular area radius (in pixels). I{(float)} 3330 @param data: The values to put back. It must be the same array as in previous 3331 L{DataField.circular_area_unextract}(). I{(const-gdouble*)} 3332 @return: 3333 """ 3334 return None
3335 - def normalize( ):
3336 """ 3337 Normalizes data in a data field to range 0.0 to 1.0. 3338 3339 It is equivalent to L{DataField.renormalize}(B{C{data_field}}, 1.0, 0.0); 3340 3341 If B{C{data_field}} is filled with only one value, it is changed to 0.0. 3342 3343 @return: 3344 """ 3345 return None
3346 - def renormalize( range , offset ):
3347 """ 3348 Transforms data in a data field with linear function to given range. 3349 3350 When B{C{range}} is positive, the new data range is (B{C{offset}}, B{C{offset}}+B{C{range}}); 3351 when B{C{range}} is negative, the new data range is (B{C{offset}}-B{C{range}}, B{C{offset}}). 3352 In neither case the data are flipped, negative range only means different 3353 selection of boundaries. 3354 3355 When B{C{range}} is zero, this method is equivalent to 3356 L{DataField.fill}(B{C{data_field}}, B{C{offset}}). 3357 3358 @param range: New data interval size. I{(float)} 3359 @param offset: New data interval offset. I{(float)} 3360 @return: 3361 """ 3362 return None
3363 - def area_renormalize( col , row , width , height , range , offset ):
3364 """ 3365 Transforms data in a part of a data field with linear function to given 3366 range. 3367 3368 When B{C{range}} is positive, the new data range is (B{C{offset}}, B{C{offset}}+B{C{range}}); 3369 when B{C{range}} is negative, the new data range is (B{C{offset}}-B{C{range}}, B{C{offset}}). 3370 In neither case the data are flipped, negative range only means different 3371 selection of boundaries. 3372 3373 When B{C{range}} is zero, this method is equivalent to 3374 L{DataField.fill}(B{C{data_field}}, B{C{offset}}). 3375 3376 Since: 2.45 3377 3378 @param col: Upper-left column coordinate. I{(int)} 3379 @param row: Upper-left row coordinate. I{(int)} 3380 @param width: Area width (number of columns). I{(int)} 3381 @param height: Area height (number of rows). I{(int)} 3382 @param range: New data interval size. I{(float)} 3383 @param offset: New data interval offset. I{(float)} 3384 @return: 3385 """ 3386 return None
3387 - def threshold( threshval , bottom , top ):
3388 """ 3389 Tresholds values of a data field. 3390 3391 Values smaller than B{C{threshold}} are set to value B{C{bottom}}, values higher 3392 than B{C{threshold}} or equal to it are set to value B{C{top}} 3393 3394 3395 @param threshval: Threshold value. I{(float)} 3396 @param bottom: Lower replacement value. I{(float)} 3397 @param top: Upper replacement value. I{(float)} 3398 @return: The total number of values above threshold. 3399 3400 """ 3401 return None
3402 - def area_threshold( col , row , width , height , threshval , bottom , top ):
3403 """ 3404 Tresholds values of a rectangular part of a data field. 3405 3406 Values smaller than B{C{threshold}} are set to value B{C{bottom}}, values higher 3407 than B{C{threshold}} or equal to it are set to value B{C{top}} 3408 3409 3410 @param col: Upper-left column coordinate. I{(int)} 3411 @param row: Upper-left row coordinate. I{(int)} 3412 @param width: Area width (number of columns). I{(int)} 3413 @param height: Area height (number of rows). I{(int)} 3414 @param threshval: Threshold value. I{(float)} 3415 @param bottom: Lower replacement value. I{(float)} 3416 @param top: Upper replacement value. I{(float)} 3417 @return: The total number of values above threshold. 3418 3419 """ 3420 return None
3421 - def clamp( bottom , top ):
3422 """ 3423 Limits data field values to a range. 3424 3425 3426 @param bottom: Lower limit value. I{(float)} 3427 @param top: Upper limit value. I{(float)} 3428 @return: The number of changed values, i.e., values that were outside 3429 [B{C{bottom}}, B{C{top}}]. 3430 3431 """ 3432 return None
3433 - def area_clamp( col , row , width , height , bottom , top ):
3434 """ 3435 Limits values in a rectangular part of a data field to a range. 3436 3437 3438 @param col: Upper-left column coordinate. I{(int)} 3439 @param row: Upper-left row coordinate. I{(int)} 3440 @param width: Area width (number of columns). I{(int)} 3441 @param height: Area height (number of rows). I{(int)} 3442 @param bottom: Lower limit value. I{(float)} 3443 @param top: Upper limit value. I{(float)} 3444 @return: The number of changed values, i.e., values that were outside 3445 [B{C{bottom}}, B{C{top}}]. 3446 3447 """ 3448 return None
3449 - def area_gather( result , buffer , hsize , vsize , average , col , row , width , height ):
3450 """ 3451 Sums or averages values in reactangular areas around each sample in a data 3452 field. 3453 3454 When the gathered area extends out of calculation area, only samples from 3455 their intersection are taken into the local sum (or average). 3456 3457 There are no restrictions on values of B{C{hsize}} and B{C{vsize}} with regard to 3458 B{C{width}} and B{C{height}}, but they have to be positive. 3459 3460 The result is calculated by the means of two-dimensional rolling sums. 3461 One one hand it means the calculation time depends linearly on 3462 (B{C{width}} + B{C{hsize}})*(B{C{height}} + B{C{vsize}}) instead of 3463 B{C{width}}*B{C{hsize}}*B{C{height}}*B{C{vsize}}. On the other hand it means absolute rounding 3464 errors of all output values are given by the largest input values, that is 3465 relative precision of results small in absolute value may be poor. 3466 3467 @param result: A data field to put the result to, it may be B{C{data_field}} itself. I{(L{DataField})} 3468 @param buffer: A data field to use as a scratch area, its size must be at least 3469 B{C{width}}*B{C{height}}. May be B{C{NULL}} to allocate a private temporary 3470 buffer. I{(L{DataField})} 3471 @param col: Upper-left column coordinate. I{(int)} 3472 @param row: Upper-left row coordinate. I{(int)} 3473 @param width: Area width (number of columns). I{(int)} 3474 @param height: Area height (number of rows). I{(int)} 3475 @param hsize: Horizontal size of gathered area. The area is centered around 3476 each sample if B{C{hsize}} is odd, it extends one pixel more to the 3477 right if B{C{hsize}} is even. I{(int)} 3478 @param vsize: Vertical size of gathered area. The area is centered around 3479 each sample if B{C{vsize}} is odd, it extends one pixel more down 3480 if B{C{vsize}} is even. I{(int)} 3481 @param average: B{C{True}} to divide resulting sums by the number of involved samples 3482 to get averages instead of sums. I{(bool)} 3483 @return: 3484 """ 3485 return None
3486 - def convolve( kernel_field ):
3487 """ 3488 Convolves a data field with given kernel. 3489 3490 @param kernel_field: Kenrel field to convolve B{C{data_field}} with. I{(L{DataField})} 3491 @return: 3492 """ 3493 return None
3494 - def area_convolve( kernel_field , col , row , width , height ):
3495 """ 3496 Convolves a rectangular part of a data field with given kernel. 3497 3498 @param kernel_field: Kenrel field to convolve B{C{data_field}} with. I{(L{DataField})} 3499 @param col: Upper-left column coordinate. I{(int)} 3500 @param row: Upper-left row coordinate. I{(int)} 3501 @param width: Area width (number of columns). I{(int)} 3502 @param height: Area height (number of rows). I{(int)} 3503 @return: 3504 """ 3505 return None
3506 - def convolve_1d( kernel_line , orientation ):
3507 """ 3508 Convolves a data field with given linear kernel. 3509 3510 Since: 2.4 3511 3512 @param kernel_line: Kenrel line to convolve B{C{data_field}} with. I{(L{DataLine})} 3513 @param orientation: Filter orientation (see L{DataField.area_convolve_1d}()). I{(Orientation)} 3514 @return: 3515 """ 3516 return None
3517 - def area_convolve_1d( kernel_line , orientation , col , row , width , height ):
3518 """ 3519 Convolves a rectangular part of a data field with given linear kernel. 3520 3521 For large separable kernels it can be more efficient to use a sequence of 3522 horizontal and vertical convolutions instead one 2D convolution. 3523 3524 Since: 2.4 3525 3526 @param kernel_line: Kernel line to convolve B{C{data_field}} with. I{(L{DataLine})} 3527 @param orientation: Filter orientation (B{C{ORIENTATION_HORIZONTAL}} for 3528 row-wise convolution, B{C{ORIENTATION_VERTICAL}} for 3529 column-wise convolution). I{(Orientation)} 3530 @param col: Upper-left column coordinate. I{(int)} 3531 @param row: Upper-left row coordinate. I{(int)} 3532 @param width: Area width (number of columns). I{(int)} 3533 @param height: Area height (number of rows). I{(int)} 3534 @return: 3535 """ 3536 return None
3537 - def filter_median( size ):
3538 """ 3539 Filters a data field with median filter. 3540 3541 @param size: Size of area to take median of. I{(int)} 3542 @return: 3543 """ 3544 return None
3545 - def area_filter_median( size , col , row , width , height ):
3546 """ 3547 Filters a rectangular part of a data field with median filter. 3548 3549 @param size: Size of area to take median of. I{(int)} 3550 @param col: Upper-left column coordinate. I{(int)} 3551 @param row: Upper-left row coordinate. I{(int)} 3552 @param width: Area width (number of columns). I{(int)} 3553 @param height: Area height (number of rows). I{(int)} 3554 @return: 3555 """ 3556 return None
3557 - def filter_mean( size ):
3558 """ 3559 Filters a data field with mean filter of size B{C{size}}. 3560 3561 @param size: Averaged area size. I{(int)} 3562 @return: 3563 """ 3564 return None
3565 - def area_filter_mean( size , col , row , width , height ):
3566 """ 3567 Filters a rectangular part of a data field with mean filter of size B{C{size}}. 3568 3569 This method is a simple L{DataField.area_gather}() wrapper. 3570 3571 @param size: Averaged area size. I{(int)} 3572 @param col: Upper-left column coordinate. I{(int)} 3573 @param row: Upper-left row coordinate. I{(int)} 3574 @param width: Area width (number of columns). I{(int)} 3575 @param height: Area height (number of rows). I{(int)} 3576 @return: 3577 """ 3578 return None
3579 - def filter_conservative( size ):
3580 """ 3581 Filters a data field with conservative denoise filter. 3582 3583 @param size: Filtered area size. I{(int)} 3584 @return: 3585 """ 3586 return None
3587 - def area_filter_conservative( size , col , row , width , height ):
3588 """ 3589 Filters a rectangular part of a data field with conservative denoise filter. 3590 3591 @param size: Filtered area size. I{(int)} 3592 @param col: Upper-left column coordinate. I{(int)} 3593 @param row: Upper-left row coordinate. I{(int)} 3594 @param width: Area width (number of columns). I{(int)} 3595 @param height: Area height (number of rows). I{(int)} 3596 @return: 3597 """ 3598 return None
3599 - def filter_laplacian( ):
3600 """ 3601 Filters a data field with Laplacian filter. 3602 3603 @return: 3604 """ 3605 return None
3606 - def area_filter_laplacian( col , row , width , height ):
3607 """ 3608 Filters a rectangular part of a data field with Laplacian filter. 3609 3610 @param col: Upper-left column coordinate. I{(int)} 3611 @param row: Upper-left row coordinate. I{(int)} 3612 @param width: Area width (number of columns). I{(int)} 3613 @param height: Area height (number of rows). I{(int)} 3614 @return: 3615 """ 3616 return None
3618 """ 3619 Filters a data field with Laplacian of Gaussians filter. 3620 3621 Since: 2.23 3622 3623 @return: 3624 """ 3625 return None
3626 - def area_filter_laplacian_of_gaussians( col , row , width , height ):
3627 """ 3628 Filters a rectangular part of a data field 3629 with Laplacian of Gaussians filter. 3630 3631 Since: 2.23 3632 3633 @param col: Upper-left column coordinate. I{(int)} 3634 @param row: Upper-left row coordinate. I{(int)} 3635 @param width: Area width (number of columns). I{(int)} 3636 @param height: Area height (number of rows). I{(int)} 3637 @return: 3638 """ 3639 return None
3640 - def filter_sobel( orientation ):
3641 """ 3642 Filters a data field with a directional Sobel filter. 3643 3644 @param orientation: Filter orientation. I{(Orientation)} 3645 @return: 3646 """ 3647 return None
3648 - def area_filter_sobel( orientation , col , row , width , height ):
3649 """ 3650 Filters a rectangular part of a data field with a directional Sobel filter. 3651 3652 @param orientation: Filter orientation. I{(Orientation)} 3653 @param col: Upper-left column coordinate. I{(int)} 3654 @param row: Upper-left row coordinate. I{(int)} 3655 @param width: Area width (number of columns). I{(int)} 3656 @param height: Area height (number of rows). I{(int)} 3657 @return: 3658 """ 3659 return None
3660 - def filter_sobel_total( ):
3661 """ 3662 Filters a data field with total Sobel filter. 3663 3664 Since: 2.31 3665 3666 @return: 3667 """ 3668 return None
3669 - def filter_prewitt( orientation ):
3670 """ 3671 Filters a data field with Prewitt filter. 3672 3673 @param orientation: Filter orientation. I{(Orientation)} 3674 @return: 3675 """ 3676 return None
3677 - def area_filter_prewitt( orientation , col , row , width , height ):
3678 """ 3679 Filters a rectangular part of a data field with a directional Prewitt 3680 filter. 3681 3682 @param orientation: Filter orientation. I{(Orientation)} 3683 @param col: Upper-left column coordinate. I{(int)} 3684 @param row: Upper-left row coordinate. I{(int)} 3685 @param width: Area width (number of columns). I{(int)} 3686 @param height: Area height (number of rows). I{(int)} 3687 @return: 3688 """ 3689 return None
3690 - def filter_prewitt_total( ):
3691 """ 3692 Filters a data field with total Prewitt filter. 3693 3694 Since: 2.31 3695 3696 @return: 3697 """ 3698 return None
3699 - def filter_slope( xder , yder ):
3700 """ 3701 Calculates x and y derivaties for an entire field. 3702 3703 The derivatives are calculated as the simple symmetrical differences (in 3704 physical units, not pixel-wise), except at the edges where the differences 3705 are one-sided. 3706 3707 Since: 2.37 3708 3709 @param xder: Data field where the x-derivarive is to be stored, or B{C{NULL}} if you 3710 are only interested in the y-derivarive. I{(L{DataField})} 3711 @param yder: Data field where the y-derivarive is to be stored, or B{C{NULL}} if you 3712 are only interested in the x-derivarive. I{(L{DataField})} 3713 @return: 3714 """ 3715 return None
3716 - def filter_dechecker( ):
3717 """ 3718 Filters a data field with 5x5 checker pattern removal filter. 3719 3720 Since: 2.1 3721 3722 @return: 3723 """ 3724 return None
3725 - def area_filter_dechecker( col , row , width , height ):
3726 """ 3727 Filters a rectangular part of a data field with 5x5 checker pattern removal 3728 filter. 3729 3730 Since: 2.1 3731 3732 @param col: Upper-left column coordinate. I{(int)} 3733 @param row: Upper-left row coordinate. I{(int)} 3734 @param width: Area width (number of columns). I{(int)} 3735 @param height: Area height (number of rows). I{(int)} 3736 @return: 3737 """ 3738 return None
3739 - def filter_gaussian( sigma ):
3740 """ 3741 Filters a data field with a Gaussian filter. 3742 3743 Since: 2.4 3744 3745 @param sigma: The sigma parameter of the Gaussian. I{(float)} 3746 @return: 3747 """ 3748 return None
3749 - def area_filter_gaussian( sigma , col , row , width , height ):
3750 """ 3751 Filters a rectangular part of a data field with a Gaussian filter. 3752 3753 The Gausian is normalized, i.e. it is sum-preserving. 3754 3755 Since: 2.4 3756 3757 @param sigma: The sigma parameter of the Gaussian. I{(float)} 3758 @param col: Upper-left column coordinate. I{(int)} 3759 @param row: Upper-left row coordinate. I{(int)} 3760 @param width: Area width (number of columns). I{(int)} 3761 @param height: Area height (number of rows). I{(int)} 3762 @return: 3763 """ 3764 return None
3765 - def filter_minimum( size ):
3766 """ 3767 Filters a data field with minimum filter. 3768 3769 @param size: Neighbourhood size for minimum search. I{(int)} 3770 @return: 3771 """ 3772 return None
3773 - def area_filter_minimum( size , col , row , width , height ):
3774 """ 3775 Filters a rectangular part of a data field with minimum filter. 3776 3777 This operation is often called erosion filter. 3778 3779 @param size: Neighbourhood size for minimum search. I{(int)} 3780 @param col: Upper-left column coordinate. I{(int)} 3781 @param row: Upper-left row coordinate. I{(int)} 3782 @param width: Area width (number of columns). I{(int)} 3783 @param height: Area height (number of rows). I{(int)} 3784 @return: 3785 """ 3786 return None
3787 - def filter_maximum( size ):
3788 """ 3789 Filters a data field with maximum filter. 3790 3791 @param size: Neighbourhood size for maximum search. I{(int)} 3792 @return: 3793 """ 3794 return None
3795 - def area_filter_maximum( size , col , row , width , height ):
3796 """ 3797 Filters a rectangular part of a data field with maximum filter. 3798 3799 This operation is often called dilation filter. 3800 3801 @param size: Neighbourhood size for maximum search. I{(int)} 3802 @param col: Upper-left column coordinate. I{(int)} 3803 @param row: Upper-left row coordinate. I{(int)} 3804 @param width: Area width (number of columns). I{(int)} 3805 @param height: Area height (number of rows). I{(int)} 3806 @return: 3807 """ 3808 return None
3809 - def area_filter_min_max( kernel , filtertype , col , row , width , height ):
3810 """ 3811 Applies a morphological operation with a flat structuring element to a 3812 part of a data field. 3813 3814 Morphological operations with flat structuring elements can be expressed 3815 using minimum (erosion) and maximum (dilation) filters that are the basic 3816 operations this function can perform. 3817 3818 The kernel field is a mask that defines the shape of the flat structuring 3819 element. It is reflected for all maximum operations (dilation). For 3820 symmetrical kernels this does not matter. You can use 3821 L{DataField.elliptic_area_fill}() to create a true circular (or 3822 elliptical) kernel. 3823 3824 The kernel is implicitly centered, i.e. it will be applied symmetrically to 3825 avoid unexpected data movement. Even-sized kernels (generally not 3826 recommended) will extend farther towards the top left image corner for 3827 minimum (erosion) and towards the bottom right corner for maximum (dilation) 3828 operations due to the reflection. If you need off-center structuring 3829 elements you can add empty rows or columns to one side of the kernel to 3830 counteract the symmetrisation. 3831 3832 The operation is linear-time in kernel size for any convex kernel. Note 3833 L{DataField.area_filter_minimum}() and 3834 L{DataField.area_filter_maximum}(), which are limited to square 3835 structuring elements, are much faster for large sizes of the squares. 3836 3837 The exterior is always handled as B{C{EXTERIOR_BORDER_EXTEND}}. 3838 3839 Since: 2.43 3840 3841 @param kernel: Data field defining the flat structuring element. I{(L{DataField})} 3842 @param filtertype: The type of filter to apply. I{(MinMaxFilterType)} 3843 @param col: Upper-left column coordinate. I{(int)} 3844 @param row: Upper-left row coordinate. I{(int)} 3845 @param width: Area width (number of columns). I{(int)} 3846 @param height: Area height (number of rows). I{(int)} 3847 @return: 3848 """ 3849 return None
3850 - def area_filter_disc_asf( radius , closing , col , row , width , height ):
3851 return None
3852 - def filter_rms( size ):
3853 """ 3854 Filters a data field with RMS filter. 3855 3856 @param size: Area size. I{(int)} 3857 @return: 3858 """ 3859 return None
3860 - def area_filter_rms( size , col , row , width , height ):
3861 """ 3862 Filters a rectangular part of a data field with RMS filter of size B{C{size}}. 3863 3864 RMS filter computes root mean square in given area. 3865 3866 @param size: Area size. I{(int)} 3867 @param col: Upper-left column coordinate. I{(int)} 3868 @param row: Upper-left row coordinate. I{(int)} 3869 @param width: Area width (number of columns). I{(int)} 3870 @param height: Area height (number of rows). I{(int)} 3871 @return: 3872 """ 3873 return None
3874 - def filter_kuwahara( ):
3875 """ 3876 Filters a data field with Kuwahara filter. 3877 3878 @return: 3879 """ 3880 return None
3881 - def area_filter_kuwahara( col , row , width , height ):
3882 """ 3883 Filters a rectangular part of a data field with a Kuwahara 3884 (edge-preserving smoothing) filter. 3885 3886 @param col: Upper-left column coordinate. I{(int)} 3887 @param row: Upper-left row coordinate. I{(int)} 3888 @param width: Area width (number of columns). I{(int)} 3889 @param height: Area height (number of rows). I{(int)} 3890 @return: 3891 """ 3892 return None
3893 - def filter_canny( threshold ):
3894 """ 3895 Filters a rectangular part of a data field with canny edge detector filter. 3896 3897 @param threshold: Slope detection threshold (range 0..1). I{(float)} 3898 @return: 3899 """ 3900 return None
3901 - def shade( target_field , theta , phi ):
3902 """ 3903 Shades a data field. 3904 3905 @param target_field: A data field to put the shade to. It will be resized to 3906 match B{C{data_field}}. I{(L{DataField})} 3907 @param theta: Shading angle (in radians, from north pole). I{(float)} 3908 @param phi: Shade orientation in xy plane (in radians, counterclockwise). I{(float)} 3909 @return: 3910 """ 3911 return None
3912 - def filter_harris( y_gradient , result , neighbourhood , alpha ):
3913 return None
3914 - def fractal_partitioning( xresult , yresult , interpolation ):
3915 """ 3916 Computes data for log-log plot by partitioning. 3917 3918 Data lines B{C{xresult}} and B{C{yresult}} will be resized to the output size and 3919 they will contain corresponding values at each position. 3920 3921 @param xresult: Data line to store x-values for log-log plot to. I{(L{DataLine})} 3922 @param yresult: Data line to store y-values for log-log plot to. I{(L{DataLine})} 3923 @param interpolation: Interpolation type. I{(InterpolationType)} 3924 @return: 3925 """ 3926 return None
3927 - def fractal_cubecounting( xresult , yresult , interpolation ):
3928 """ 3929 Computes data for log-log plot by cube counting. 3930 3931 Data lines B{C{xresult}} and B{C{yresult}} will be resized to the output size and 3932 they will contain corresponding values at each position. 3933 3934 @param xresult: Data line to store x-values for log-log plot to. I{(L{DataLine})} 3935 @param yresult: Data line to store y-values for log-log plot to. I{(L{DataLine})} 3936 @param interpolation: Interpolation type. I{(InterpolationType)} 3937 @return: 3938 """ 3939 return None
3940 - def fractal_triangulation( xresult , yresult , interpolation ):
3941 """ 3942 Computes data for log-log plot by triangulation. 3943 3944 Data lines B{C{xresult}} and B{C{yresult}} will be resized to the output size and 3945 they will contain corresponding values at each position. 3946 3947 @param xresult: Data line to store x-values for log-log plot to. I{(L{DataLine})} 3948 @param yresult: Data line to store y-values for log-log plot to. I{(L{DataLine})} 3949 @param interpolation: Interpolation type. I{(InterpolationType)} 3950 @return: 3951 """ 3952 return None
3953 - def fractal_psdf( xresult , yresult , interpolation ):
3954 """ 3955 Computes data for log-log plot by spectral density method. 3956 3957 Data lines B{C{xresult}} and B{C{yresult}} will be resized to the output size and 3958 they will contain corresponding values at each position. 3959 3960 @param xresult: Data line to store x-values for log-log plot to. I{(L{DataLine})} 3961 @param yresult: Data line to store y-values for log-log plot to. I{(L{DataLine})} 3962 @param interpolation: Interpolation type. I{(InterpolationType)} 3963 @return: 3964 """ 3965 return None
3966 - def fractal_correction( mask_field , interpolation ):
3967 """ 3968 Replaces data under mask with interpolated values using fractal 3969 interpolation. 3970 3971 @param mask_field: Mask of places to be corrected. I{(L{DataField})} 3972 @param interpolation: Interpolation type. I{(InterpolationType)} 3973 @return: 3974 """ 3975 return None
3976 - def grains_mark_curvature( grain_field , threshval , below ):
3977 """ 3978 Marks data that are above/below curvature threshold. 3979 3980 @param grain_field: Data field to store the resulting mask to. I{(L{DataField})} 3981 @param threshval: Relative curvature threshold, in percents. I{(float)} 3982 @param below: If B{C{True}}, data below threshold are marked, otherwise data above 3983 threshold are marked. I{(bool)} 3984 @return: 3985 """ 3986 return None
3987 - def grains_mark_watershed( grain_field , locate_steps , locate_thresh , locate_dropsize , wshed_steps , wshed_dropsize , prefilter , below ):
3988 """ 3989 Performs watershed algorithm. 3990 3991 @param grain_field: Result of marking (mask). I{(L{DataField})} 3992 @param locate_steps: Locating algorithm steps. I{(int)} 3993 @param locate_thresh: Locating algorithm threshold. I{(int)} 3994 @param locate_dropsize: Locating drop size. I{(float)} 3995 @param wshed_steps: Watershed steps. I{(int)} 3996 @param wshed_dropsize: Watershed drop size. I{(float)} 3997 @param prefilter: Use prefiltering. I{(bool)} 3998 @param below: If B{C{True}}, valleys are marked, otherwise mountains are marked. I{(bool)} 3999 @return: 4000 """ 4001 return None
4002 - def grains_remove_grain( col , row ):
4003 """ 4004 Removes one grain at given position. 4005 4006 4007 @param col: Column inside a grain. I{(int)} 4008 @param row: Row inside a grain. I{(int)} 4009 @return: B{C{True}} if a grain was actually removed (i.e., (B{C{col}},B{C{row}}) was 4010 inside a grain). 4011 4012 """ 4013 return None
4014 - def grains_extract_grain( col , row ):
4015 """ 4016 Removes all grains except that one at given position. 4017 4018 If there is no grain at (B{C{col}}, B{C{row}}), all grains are removed. 4019 4020 4021 @param col: Column inside a grain. I{(int)} 4022 @param row: Row inside a grain. I{(int)} 4023 @return: B{C{True}} if a grain remained (i.e., (B{C{col}},B{C{row}}) was inside a grain). 4024 4025 """ 4026 return None
4027 - def grains_remove_by_number( number ):
4028 """ 4029 Removes grain identified by B{C{number}}. 4030 4031 Since: 2.35 4032 4033 @param number: Grain number was filled by L{DataField.number_grains}(). I{(int)} 4034 @return: 4035 """ 4036 return None
4037 - def grains_remove_by_size( size ):
4038 """ 4039 Removes all grains below specified area. 4040 4041 @param size: Grain area threshold, in square pixels. I{(int)} 4042 @return: 4043 """ 4044 return None
4045 - def grains_remove_by_height( grain_field , threshval , below ):
4046 """ 4047 Removes grains that are higher/lower than given threshold value. 4048 4049 @param grain_field: Field of marked grains (mask) I{(L{DataField})} 4050 @param threshval: Relative height threshold, in percents. I{(float)} 4051 @param below: If B{C{True}}, grains below threshold are removed, otherwise grains above 4052 threshold are removed. I{(bool)} 4053 @return: 4054 """ 4055 return None
4057 """ 4058 Removes all grains that touch field borders. 4059 4060 Since: 2.30 4061 4062 @return: 4063 """ 4064 return None
4065 - def UNIMPLEMENTED_grains_watershed_init( grain_field , locate_steps , locate_thresh , locate_dropsize , wshed_steps , wshed_dropsize , prefilter , below ):
4066 """ 4067 Initializes the watershed algorithm. 4068 4069 This iterator reports its state as B{C{WatershedStateType}}. 4070 4071 4072 @param grain_field: Result of marking (mask). I{(L{DataField})} 4073 @param locate_steps: Locating algorithm steps. I{(int)} 4074 @param locate_thresh: Locating algorithm threshold. I{(int)} 4075 @param locate_dropsize: Locating drop size. I{(float)} 4076 @param wshed_steps: Watershed steps. I{(int)} 4077 @param wshed_dropsize: Watershed drop size. I{(float)} 4078 @param prefilter: Use prefiltering. I{(bool)} 4079 @param below: If B{C{True}}, valleys are marked, otherwise mountains are marked. I{(bool)} 4080 @return: A new watershed iterator. 4081 4082 """ 4083 return None
4084 - def grains_mark_height( grain_field , threshval , below ):
4085 """ 4086 Marks data that are above/below height threshold. 4087 4088 @param grain_field: Data field to store the resulting mask to. I{(L{DataField})} 4089 @param threshval: Relative height threshold, in percents. I{(float)} 4090 @param below: If B{C{True}}, data below threshold are marked, otherwise data above 4091 threshold are marked. I{(bool)} 4092 @return: 4093 """ 4094 return None
4095 - def grains_mark_slope( grain_field , threshval , below ):
4096 """ 4097 Marks data that are above/below slope threshold. 4098 4099 @param grain_field: Data field to store the resulting mask to. I{(L{DataField})} 4100 @param threshval: Relative slope threshold, in percents. I{(float)} 4101 @param below: If B{C{True}}, data below threshold are marked, otherwise data above 4102 threshold are marked. I{(bool)} 4103 @return: 4104 """ 4105 return None
4106 - def otsu_threshold( ):
4107 """ 4108 Finds Otsu's height threshold for a data field. 4109 4110 The Otsu's threshold is optimal in the sense that it minimises the 4111 inter-class variances of two classes of pixels: above and below theshold. 4112 4113 Since: 2.37 4114 4115 @return: 4116 """ 4117 return None
4118 - def grains_add( add_field ):
4119 """ 4120 Adds B{C{add_field}} grains to B{C{grain_field}}. 4121 4122 Note: This function is equivalent to 4123 |[ 4124 L{DataField.max_of_fields}(grain_field, grain_field, add_field); 4125 ]| 4126 4127 @param add_field: Field of marked grains (mask) to be added. I{(L{DataField})} 4128 @return: 4129 """ 4130 return None
4131 - def grains_intersect( intersect_field ):
4132 """ 4133 Performs intersection betweet two grain fields, 4134 result is stored in B{C{grain_field}}. 4135 4136 Note: This function is equivalent to 4137 |[ 4138 L{DataField.min_of_fields}(grain_field, grain_field, intersect_field); 4139 ]| 4140 4141 @param intersect_field: Field of marked grains (mask). I{(L{DataField})} 4142 @return: 4143 """ 4144 return None
4145 - def grains_invert( ):
4146 """ 4147 Inverts a data field representing a mask. 4148 4149 All non-positive values are transformed to 1.0. All positive values are 4150 transformed to 0.0. 4151 4152 Since: 2.43 4153 4154 @return: 4155 """ 4156 return None
4157 - def UNIMPLEMENTED_grains_autocrop( symmetrically , left , right , up , down ):
4158 """ 4159 Removes empty border rows and columns from a data field representing a mask. 4160 4161 If there are border rows and columns filled completely with non-positive 4162 values the size of the data field is reduced, removing these rows. The 4163 parameter B{C{symmetrically}} controls whether the size reduction is maximum 4164 possible or symmetrical. 4165 4166 When there is no positive value in the field the field size is reduced to 4167 the smallest possible. This means 1x1 for B{C{symmetrical}} being B{C{False}} and 4168 even original dimensions to 2 for B{C{symmetrical}} being B{C{True}}. 4169 4170 Since: 2.43 4171 4172 @param symmetrically: B{C{True}} to remove borders symmetrically, i.e the same number 4173 of pixels from left and right, and also top and bottom. 4174 B{C{False}} to remove as many empty rows and columns as possible. I{(bool)} 4175 @param left: Location to store how many column were removed from the left, or 4176 B{C{NULL}}. I{(guint*)} 4177 @param right: Location to store how many column were removed from the right, or 4178 B{C{NULL}}. I{(guint*)} 4179 @param up: Location to store how many row were removed from the top, or B{C{NULL}}. I{(guint*)} 4180 @param down: Location to store how many row were removed from the bottom, or 4181 B{C{NULL}}. I{(guint*)} 4182 @return: B{C{True}} if the field size was reduced at all. Detailed information 4183 about the reduction can be obtained from B{C{left}}, B{C{right}}, B{C{up}} and 4184 B{C{down}}. 4185 4186 4187 """ 4188 return None
4189 - def number_grains( grains ):
4190 """ 4191 Create a tuple of integer grain numbers in the data field representing a 4192 mask. 4193 4194 4195 @return: tuple of grain numbers for each piel 4196 4197 """ 4198 return None
4199 - def number_grains_periodic( grains ):
4200 """ 4201 Numbers grains in a periodic mask data field. 4202 4203 This function differs from L{DataField.number_grains}() by the assumption 4204 of periodicity, i.e. grains can touch across the opposite field edges. 4205 4206 Since: 2.38 4207 4208 @param grains: Zero-filled array of integers of equal size to B{C{mask_field}} to put 4209 grain numbers to. Empty space will be left 0, pixels inside a 4210 grain will be set to grain number. Grains are numbered 4211 sequentially 1, 2, 3, ... I{(gint*)} 4212 @return: The number of last grain (note they are numbered from 1). 4213 4214 4215 """ 4216 return None
4217 - def get_grain_bounding_boxes( ngrains , grains , bboxes ):
4218 """ 4219 Find bounding boxes of all grains. 4220 4221 Since: 2.3 4222 4223 @param ngrains: The number of grains as returned by 4224 L{DataField.number_grains}(). I{(int)} 4225 @param grains: Grain numbers filled with L{DataField.number_grains}(). I{(const-gint*)} 4226 @param bboxes: Array of size at least 4*(B{C{ngrains}}+1) to fill with grain bounding 4227 boxes (as usual zero does not correspond to any grain, grains 4228 start from 1). The bounding boxes are stored as quadruples of 4229 indices: (xmin, ymin, width, height). It can be B{C{NULL}} to allocate 4230 a new array. I{(gint*)} 4231 @return: Either B{C{bboxes}} (if it was not B{C{NULL}}), or a newly allocated array 4232 of size 4(B{C{ngrains}} + 1). 4233 4234 4235 """ 4236 return None
4237 - def grains_get_distribution( grain_field , distribution , ngrains , grains , quantity , nstats ):
4238 """ 4239 Computes distribution of requested grain characteristics. 4240 4241 Puts number of grains vs. grain value data into B{C{distribution}}, units, scales 4242 and offsets of B{C{distribution}} are updated accordingly. 4243 4244 Note the B{C{i}}-th bin is [B{C{i}}*B{C{dx}}+B{C{off}},(B{C{i}}+1)*B{C{dx}}+B{C{off}}] so the central value 4245 you probably want to use for plotting is (B{C{i}}+0.5)*B{C{dx}}+B{C{off}} (where B{C{dx}} is 4246 the B{C{distribution}} data line pixel size, B{C{off}} is its offset). 4247 4248 4249 @param grain_field: Data field (mask) of marked grains. Note if you pass 4250 non-B{C{NULL}} B{C{grains}} all grain information is taken from it and 4251 B{C{grain_field}} can be even B{C{NULL}} then. I{(L{DataField})} 4252 @param distribution: Data line to store grain distribution to. I{(L{DataLine})} 4253 @param grains: Grain numbers filled with L{DataField.number_grains}() if you 4254 have it, or B{C{NULL}} (the function then finds grain numbers itself 4255 which is not efficient for repeated use on the same grain field). I{(const-gint*)} 4256 @param ngrains: The number of grains as returned by 4257 L{DataField.number_grains}(). Ignored in B{C{grains}} is B{C{NULL}}. I{(int)} 4258 @param quantity: The quantity to calculate. I{(GrainQuantity)} 4259 @param nstats: The number of samples to take on the distribution function. If 4260 nonpositive, a suitable resolution is determined automatically. I{(int)} 4261 @return: A data line with the distribution: B{C{distribution}} itself if it was 4262 not B{C{NULL}}, otherwise a newly created B{C{DataLine}} caller must 4263 destroy. If there are no grains, B{C{NULL}} is returned and 4264 B{C{distribution}} is not changed. 4265 4266 """ 4267 return None
4268 - def grains_get_values( values , ngrains , grains , quantity ):
4269 """ 4270 Obtains values of one grain quantity for all grains. 4271 4272 The zeroth value corresponds to the empty space between grains and isn't 4273 meaningful in general. 4274 4275 4276 @param quantity: Grain quantity. I{(GrainQuantity)} 4277 @return: tuple of values of the grain quantity 4278 4279 """ 4280 return None
4281 - def UNIMPLEMENTED_grains_get_quantities( values , quantities , nquantities , ngrains , grains ):
4282 """ 4283 Calculates multiple characteristics of grains simultaneously. 4284 4285 See L{DataField.grains_get_values}() for some discussion. This function 4286 is more efficient if several grain quantities need to be calculated since 4287 L{DataField.grains_get_values}() can do lot of repeated work in such case. 4288 4289 Since: 2.22 4290 4291 @param values: Array of B{C{nquantities}} pointers to blocks of length B{C{ngrains}}+1 to 4292 put the calculated grain values to. Each block corresponds to one 4293 requested quantity. B{C{NULL}} can be passed to allocate and return a 4294 new array. I{(gdouble**)} 4295 @param quantities: Array of B{C{nquantities}} items that specify the requested 4296 B{C{GrainQuantity}} to put to corresponding items in B{C{values}}. 4297 Quantities can repeat. I{(const-GrainQuantity*)} 4298 @param nquantities: The number of requested different grain values. I{(int)} 4299 @param grains: Grain numbers filled with L{DataField.number_grains}(). I{(const-gint*)} 4300 @param ngrains: The number of grains as returned by 4301 L{DataField.number_grains}(). I{(int)} 4302 @return: B{C{values}} itself if it was not B{C{NULL}}, otherwise a newly allocated 4303 array that caller has to free with g_free(), including the 4304 contained arrays. 4305 4306 4307 """ 4308 return None
4309 - def area_grains_tgnd( target_line , col , row , width , height , below , nstats ):
4310 """ 4311 Calculates threshold grain number distribution. 4312 4313 This function is a simple L{DataField.area_grains_tgnd_range}() that 4314 calculates the distribution in the full range. 4315 4316 @param target_line: A data line to store the distribution to. It will be 4317 resampled to the requested width. I{(L{DataLine})} 4318 @param col: Upper-left column coordinate. I{(int)} 4319 @param row: Upper-left row coordinate. I{(int)} 4320 @param width: Area width (number of columns). I{(int)} 4321 @param height: Area height (number of rows). I{(int)} 4322 @param below: If B{C{True}}, valleys are marked, otherwise mountains are marked. I{(bool)} 4323 @param nstats: The number of samples to take on the distribution function. If 4324 nonpositive, a suitable resolution is determined automatically. I{(int)} 4325 @return: 4326 """ 4327 return None
4328 - def area_grains_tgnd_range( target_line , col , row , width , height , min , max , below , nstats ):
4329 """ 4330 Calculates threshold grain number distribution in given height range. 4331 4332 This is the number of grains for each of B{C{nstats}} equidistant height 4333 threshold levels. For large B{C{nstats}} this function is much faster than the 4334 equivalent number of L{DataField.grains_mark_height}() calls. 4335 4336 @param target_line: A data line to store the distribution to. It will be 4337 resampled to the requested width. I{(L{DataLine})} 4338 @param col: Upper-left column coordinate. I{(int)} 4339 @param row: Upper-left row coordinate. I{(int)} 4340 @param width: Area width (number of columns). I{(int)} 4341 @param height: Area height (number of rows). I{(int)} 4342 @param min: Minimum threshold value. I{(float)} 4343 @param max: Maximum threshold value. I{(float)} 4344 @param below: If B{C{True}}, valleys are marked, otherwise mountains are marked. I{(bool)} 4345 @param nstats: The number of samples to take on the distribution function. If 4346 nonpositive, a suitable resolution is determined automatically. I{(int)} 4347 @return: 4348 """ 4349 return None
4350 - def grains_splash_water( minima , locate_steps , locate_dropsize ):
4351 return None
4353 """ 4354 Performs Euclidean distance transform of a data field with grains. 4355 4356 Each non-zero value will be replaced with Euclidean distance to the grain 4357 boundary, measured in pixels. 4358 4359 See also L{DataField.grain_simple_dist_trans}() for simple distance 4360 transforms such as city-block or chessboard. 4361 4362 Since: 2.36 4363 4364 @return: 4365 """ 4366 return None
4367 - def grain_simple_dist_trans( dtype , from_border ):
4368 """ 4369 Performs a distance transform of a data field with grains. 4370 4371 Each non-zero value will be replaced with a distance to the grain boundary, 4372 measured in pixels. 4373 4374 Note this function can calculate the Euclidean distance transform only since 4375 2.43. Use L{DataField.grain_distance_transform}() for the EDT if you need 4376 compatibility with older versions. 4377 4378 Since: 2.41 4379 4380 @param dtype: Type of simple distance to use. I{(DistanceTransformType)} 4381 @param from_border: B{C{True}} to consider image edges to be grain boundaries. I{(bool)} 4382 @return: 4383 """ 4384 return None
4385 - def grains_shrink( amount , dtype , from_border ):
4386 """ 4387 Erodes a data field containing mask by specified amount using a distance 4388 measure. 4389 4390 Non-zero pixels in B{C{data_field}} will be replaced with zeroes if they are not 4391 farther than B{C{amount}} from the grain boundary as defined by B{C{dtype}}. 4392 4393 Since: 2.43 4394 4395 @param amount: How much the grains should be reduced, in pixels. It is inclusive, 4396 i.e. pixels that are B{C{amount}} far from the border will be removed. I{(float)} 4397 @param dtype: Type of simple distance to use. I{(DistanceTransformType)} 4398 @param from_border: B{C{True}} to consider image edges to be grain boundaries. 4399 B{C{False}} to reduce grains touching field boundaries only along 4400 the boundaries. I{(bool)} 4401 @return: 4402 """ 4403 return None
4404 - def grains_grow( amount , dtype , prevent_merging ):
4405 """ 4406 Dilates a data field containing mask by specified amount using a distance 4407 measure. 4408 4409 Non-positive pixels in B{C{data_field}} will be replaced with ones if they are 4410 not farther than B{C{amount}} from the grain boundary as defined by B{C{dtype}}. 4411 4412 Since: 2.43 4413 4414 @param amount: How much the grains should be expanded, in pixels. It is 4415 inclusive, i.e. exterior pixels that are B{C{amount}} far from the 4416 border will be filled. I{(float)} 4417 @param dtype: Type of simple distance to use. I{(DistanceTransformType)} 4418 @param prevent_merging: B{C{True}} to prevent grain merging, i.e. the growth stops 4419 where two grains would merge. B{C{False}} to simply expand the 4420 grains, without regard to grain connectivity. I{(bool)} 4421 @return: 4422 """ 4423 return None
4424 - def fill_voids( nonsimple ):
4425 """ 4426 Fills voids in grains in a data field representing a mask. 4427 4428 Voids in grains are zero pixels in B{C{data_field}} from which no path exists 4429 through other zero pixels to the field boundary. The paths are considered 4430 in 8-connectivity because grains themselves are considered in 4431 4-connectivity. 4432 4433 Since: 2.37 4434 4435 @param nonsimple: Pass B{C{True}} to fill also voids that are not simple-connected 4436 (e.g. ring-like). This can result in grain merging if a small 4437 grain is contained within a void. Pass B{C{False}} to fill only 4438 simple-connected grains. I{(bool)} 4439 @return: B{C{True}} if any voids were filled at all, B{C{False}} if no change was 4440 made. 4441 4442 4443 """ 4444 return None
4445 - def UNIMPLEMENTED_waterpour( result , grains ):
4446 """ 4447 Performs the classical Vincent watershed segmentation of a data field. 4448 4449 The segmentation always results in the entire field being masked with the 4450 exception of thin (8-connectivity) lines separating the segments (grains). 4451 4452 Compared to L{DataField.grains_mark_watershed}(), this algorithm is very 4453 fast. However, when used alone, it typically results in a serious 4454 oversegmentation as each local minimum gives raise to a grain. Furthermore, 4455 the full segmentation means that also pixels which would be considered 4456 outside any grain in the topographical sense will be assigned to some 4457 catchment basin. Therefore, pre- or postprocessing is usually necessary, 4458 using the gradient image or a more sophisticated method. 4459 4460 The function does not assign pixels with value B{C{HUGE_VAL}} or larger to any 4461 segment. This can be used to pre-mark certain areas explicitly as 4462 boundaries. 4463 4464 Since the algorithm numbers the grains as a side effect, you can pass a 4465 B{C{grains}} array and get the grain numbers immediatelly, avoiding the 4466 relatively (although not drastically) expensive 4467 L{DataField.number_grains}() call. 4468 4469 Since: 2.37 4470 4471 @param result: Data field that will be filled with the resulting mask. It will be 4472 resized to the dimensions of B{C{data_field}} and its properties set 4473 accordingly. I{(L{DataField})} 4474 @param grains: Optionally, an array with the same number of items as B{C{data_field}}. 4475 If non-B{C{NULL}}, it will be filled with grain numbers in the same 4476 manner as L{DataField.number_grains}(). Pass B{C{NULL}} to ignore. I{(gint*)} 4477 @return: The number of segments (grains) in the result, excluding the 4478 separators, i.e. the same convention as in 4479 L{DataField.number_grains}() is used. 4480 4481 4482 """ 4483 return None
4484 - def mark_extrema( extrema , maxima ):
4485 return None
4486 - def hough_line( x_gradient , y_gradient , result , hwidth , overlapping ):
4487 return None
4488 - def hough_circle( x_gradient , y_gradient , result , radius ):
4489 return None
4490 - def hough_line_strenghten( x_gradient , y_gradient , hwidth , threshold ):
4491 return None
4492 - def hough_circle_strenghten( x_gradient , y_gradient , radius , threshold ):
4493 return None
4494 - def UNIMPLEMENTED_get_local_maxima_list( xdata , ydata , zdata , ndata , skip , threshold , subpixel ):
4495 return None
4496 - def hough_polar_line_to_datafield( rho , theta , px1 , px2 , py1 , py2 ):
4497 return None
4498 - def a_1dfft( iin , rout , iout , orientation , windowing , direction , interpolation , preserverms , level ):
4499 """ 4500 Transforms all rows or columns in a data field with Fast Fourier Transform. 4501 4502 If requested a windowing and/or leveling is applied to preprocess data to 4503 obtain reasonable results. 4504 4505 @param iin: Imaginary input data field. It can be B{C{NULL}} for real-to-complex 4506 transform which can be somewhat faster than complex-to-complex 4507 transform. I{(L{DataField})} 4508 @param rout: Real output data field, it will be resized to area size. I{(L{DataField})} 4509 @param iout: Imaginary output data field, it will be resized to area size. I{(L{DataField})} 4510 @param orientation: Orientation: pass B{C{ORIENTATION_HORIZONTAL}} to 4511 transform rows, B{C{ORIENTATION_VERTICAL}} to transform 4512 columns. I{(Orientation)} 4513 @param windowing: Windowing type. I{(WindowingType)} 4514 @param direction: FFT direction. I{(TransformDirection)} 4515 @param interpolation: Interpolation type. 4516 Ignored since 2.8 as no resampling is performed. I{(InterpolationType)} 4517 @param preserverms: B{C{True}} to preserve RMS while windowing. I{(bool)} 4518 @param level: 0 to perform no leveling, 1 to subtract mean value, 2 to subtract 4519 line (the number can be interpreted as the first polynomial degree 4520 to keep, but only the enumerated three values are available). I{(int)} 4521 @return: 4522 """ 4523 return None
4524 - def area_1dfft( iin , rout , iout , col , row , width , height , orientation , windowing , direction , interpolation , preserverms , level ):
4525 """ 4526 Transforms all rows or columns in a rectangular part of a data field with 4527 Fast Fourier Transform. 4528 4529 If requested a windowing and/or leveling is applied to preprocess data to 4530 obtain reasonable results. 4531 4532 @param iin: Imaginary input data field. It can be B{C{NULL}} for real-to-complex 4533 transform which can be somewhat faster than complex-to-complex 4534 transform. I{(L{DataField})} 4535 @param rout: Real output data field, it will be resized to area size. I{(L{DataField})} 4536 @param iout: Imaginary output data field, it will be resized to area size. I{(L{DataField})} 4537 @param col: Upper-left column coordinate. I{(int)} 4538 @param row: Upper-left row coordinate. I{(int)} 4539 @param width: Area width (number of columns), must be at least 2 for horizontal 4540 transforms. I{(int)} 4541 @param height: Area height (number of rows), must be at least 2 for vertical 4542 transforms. I{(int)} 4543 @param orientation: Orientation: pass B{C{ORIENTATION_HORIZONTAL}} to 4544 transform rows, B{C{ORIENTATION_VERTICAL}} to transform 4545 columns. I{(Orientation)} 4546 @param windowing: Windowing type. I{(WindowingType)} 4547 @param direction: FFT direction. I{(TransformDirection)} 4548 @param interpolation: Interpolation type. 4549 Ignored since 2.8 as no resampling is performed. I{(InterpolationType)} 4550 @param preserverms: B{C{True}} to preserve RMS while windowing. I{(bool)} 4551 @param level: 0 to perform no leveling, 1 to subtract mean value, 2 to subtract 4552 lines (the number can be interpreted as the first polynomial degree 4553 to keep, but only the enumerated three values are available). I{(int)} 4554 @return: 4555 """ 4556 return None
4557 - def a_1dfft_raw( iin , rout , iout , orientation , direction ):
4558 """ 4559 Transforms all rows or columns in a data field with Fast Fourier Transform. 4560 4561 No leveling, windowing nor scaling is performed. 4562 4563 Since 2.8 the dimensions need not to be from the set of sizes returned 4564 by L{gwy_fft_find_nice_size}(). 4565 4566 Since: 2.1 4567 4568 @param iin: Imaginary input data field. It can be B{C{NULL}} for real-to-complex 4569 transform. I{(L{DataField})} 4570 @param rout: Real output data field, it will be resized to B{C{rin}} size. I{(L{DataField})} 4571 @param iout: Imaginary output data field, it will be resized to B{C{rin}} size. I{(L{DataField})} 4572 @param orientation: Orientation: pass B{C{ORIENTATION_HORIZONTAL}} to 4573 transform rows, B{C{ORIENTATION_VERTICAL}} to transform 4574 columns. I{(Orientation)} 4575 @param direction: FFT direction. I{(TransformDirection)} 4576 @return: 4577 """ 4578 return None
4579 - def a_2dfft( iin , rout , iout , windowing , direction , interpolation , preserverms , level ):
4580 """ 4581 Calculates 2D Fast Fourier Transform of a rectangular a data field. 4582 4583 If requested a windowing and/or leveling is applied to preprocess data to 4584 obtain reasonable results. 4585 4586 Lateral dimensions, offsets and units are unchanged. See 4587 L{DataField.fft_postprocess}() for that. 4588 4589 @param iin: Imaginary input data field. It can be B{C{NULL}} for real-to-complex 4590 transform which can be somewhat faster than complex-to-complex 4591 transform. I{(L{DataField})} 4592 @param rout: Real output data field, it will be resized to area size. I{(L{DataField})} 4593 @param iout: Imaginary output data field, it will be resized to area size. I{(L{DataField})} 4594 @param windowing: Windowing type. I{(WindowingType)} 4595 @param direction: FFT direction. I{(TransformDirection)} 4596 @param interpolation: Interpolation type. I{(InterpolationType)} 4597 @param preserverms: B{C{True}} to preserve RMS while windowing. I{(bool)} 4598 @param level: 0 to perform no leveling, 1 to subtract mean value, 2 to subtract 4599 plane (the number can be interpreted as the first polynomial degree 4600 to keep, but only the enumerated three values are available). I{(int)} 4601 @return: 4602 """ 4603 return None
4604 - def area_2dfft( iin , rout , iout , col , row , width , height , windowing , direction , interpolation , preserverms , level ):
4605 """ 4606 Calculates 2D Fast Fourier Transform of a rectangular area of a data field. 4607 4608 If requested a windowing and/or leveling is applied to preprocess data to 4609 obtain reasonable results. 4610 4611 @param iin: Imaginary input data field. It can be B{C{NULL}} for real-to-complex 4612 transform which can be somewhat faster than complex-to-complex 4613 transform. I{(L{DataField})} 4614 @param rout: Real output data field, it will be resized to area size. I{(L{DataField})} 4615 @param iout: Imaginary output data field, it will be resized to area size. I{(L{DataField})} 4616 @param col: Upper-left column coordinate. I{(int)} 4617 @param row: Upper-left row coordinate. I{(int)} 4618 @param width: Area width (number of columns), must be at least 2. I{(int)} 4619 @param height: Area height (number of rows), must be at least 2. I{(int)} 4620 @param windowing: Windowing type. I{(WindowingType)} 4621 @param direction: FFT direction. I{(TransformDirection)} 4622 @param interpolation: Interpolation type. 4623 Ignored since 2.8 as no resampling is performed. I{(InterpolationType)} 4624 @param preserverms: B{C{True}} to preserve RMS while windowing. I{(bool)} 4625 @param level: 0 to perform no leveling, 1 to subtract mean value, 2 to subtract 4626 plane (the number can be interpreted as the first polynomial degree 4627 to keep, but only the enumerated three values are available). I{(int)} 4628 @return: 4629 """ 4630 return None
4631 - def a_2dfft_raw( iin , rout , iout , direction ):
4632 """ 4633 Calculates 2D Fast Fourier Transform of a data field. 4634 4635 No leveling, windowing nor scaling is performed. 4636 4637 Since 2.8 the dimensions need not to be from the set of sizes returned 4638 by L{gwy_fft_find_nice_size}(). 4639 4640 Lateral dimensions, offsets and units are unchanged. See 4641 L{DataField.fft_postprocess}() for that. 4642 4643 Since: 2.1 4644 4645 @param iin: Imaginary input data field. It can be B{C{NULL}} for real-to-complex 4646 transform. I{(L{DataField})} 4647 @param rout: Real output data field, it will be resized to B{C{rin}} size. I{(L{DataField})} 4648 @param iout: Imaginary output data field, it will be resized to B{C{rin}} size. I{(L{DataField})} 4649 @param direction: FFT direction. I{(TransformDirection)} 4650 @return: 4651 """ 4652 return None
4653 - def a_2dfft_humanize( ):
4654 """ 4655 Rearranges 2D FFT output to a human-friendly form. 4656 4657 Top-left, top-right, bottom-left and bottom-right sub-rectangles are swapped 4658 to obtain a humanized 2D FFT output with (0,0) in the centre. 4659 4660 More precisely, for even field dimensions the equally-sized blocks starting 4661 with the Nyquist frequency and with the zero frequency (constant component) 4662 will exchange places. For odd field dimensions, the block containing the 4663 zero frequency is one item larger and the constant component will actually 4664 end up in the exact centre. 4665 4666 Also note if both dimensions are even, this function is involutory and 4667 identical to L{DataField.2dfft_dehumanize}(). However, if any dimension 4668 is odd, L{DataField.2dfft_humanize}() and 4669 L{DataField.2dfft_dehumanize}() are different, therefore they must be 4670 paired properly. 4671 4672 @return: 4673 """ 4674 return None
4675 - def a_2dfft_dehumanize( ):
4676 """ 4677 Rearranges 2D FFT output back from the human-friendly form. 4678 4679 Top-left, top-right, bottom-left and bottom-right sub-rectangles are swapped 4680 to reshuffle a humanized 2D FFT output back into the natural positions. 4681 4682 See L{DataField.2dfft_humanize}() for discussion. 4683 4684 Since: 2.8 4685 4686 @return: 4687 """ 4688 return None
4689 - def fft_postprocess( humanize ):
4690 """ 4691 Updates units, dimensions and offsets for a 2D FFT-processed field. 4692 4693 The field is expected to have dimensions and units of the original 4694 direct-space data. The lateral units and resolutions are updated to 4695 correspond to its Fourier transform. 4696 4697 If B{C{humanize}} is B{C{True}} L{DataField.2dfft_humanize}() is applied to the 4698 field data and the lateral offsets are set accordingly. Otherwise the 4699 offsets are cleared. 4700 4701 Value units are kept intact. 4702 4703 Since: 2.38 4704 4705 @param humanize: B{C{True}} to rearrange data to have the frequency origin in the 4706 centre. I{(bool)} 4707 @return: 4708 """ 4709 return None
4710 - def fft_filter_1d( result_field , weights , orientation , interpolation ):
4711 """ 4712 Performs 1D FFT filtering of a data field. 4713 4714 @param result_field: A data field to store the result to. It will be resampled 4715 to B{C{data_field}}'s size. I{(L{DataField})} 4716 @param weights: Filter weights for the lower half of the spectrum (the other 4717 half is symmetric). Its size can be arbitrary, it will be 4718 interpolated. I{(L{DataLine})} 4719 @param orientation: Filter direction. I{(Orientation)} 4720 @param interpolation: The interpolation to use for resampling. I{(InterpolationType)} 4721 @return: 4722 """ 4723 return None
4724 - def UNIMPLEMENTED_cwt( interpolation , scale , wtype ):
4725 """ 4726 Computes a continuous wavelet transform (CWT) at given 4727 scale and using given wavelet. 4728 4729 @param interpolation: Interpolation type. 4730 Ignored since 2.8 as no resampling is performed. I{(InterpolationType)} 4731 @param scale: Wavelet scale. I{(float)} 4732 @param wtype: Wavelet type. I{(2DCWTWaveletType)} 4733 @return: 4734 """ 4735 return None
4736 - def area_fit_plane( mask , col , row , width , height , pa , pbx , pby ):
4737 """ 4738 Fits a plane through a rectangular part of a data field. 4739 4740 The coefficients can be used for plane leveling using the same relation 4741 as in L{DataField.fit_plane}(), counting indices from area top left 4742 corner. 4743 4744 @param mask: Mask of values to take values into account, or B{C{NULL}} for full 4745 B{C{data_field}}. Values equal to 0.0 and below cause corresponding 4746 B{C{data_field}} samples to be ignored, values equal to 1.0 and above 4747 cause inclusion of corresponding B{C{data_field}} samples. The behaviour 4748 for values inside (0.0, 1.0) is undefined (it may be specified 4749 in the future). I{(L{DataField})} 4750 @param col: Upper-left column coordinate. I{(int)} 4751 @param row: Upper-left row coordinate. I{(int)} 4752 @param width: Area width (number of columns). I{(int)} 4753 @param height: Area height (number of rows). I{(int)} 4754 @param pa: Where constant coefficient should be stored (or B{C{NULL}}). I{(float)} 4755 @param pbx: Where x plane coefficient should be stored (or B{C{NULL}}). I{(float)} 4756 @param pby: Where y plane coefficient should be stored (or B{C{NULL}}). I{(float)} 4757 @return: 4758 """ 4759 return None
4760 - def fit_plane( pa , pbx , pby ):
4761 """ 4762 Fits a plane through a data field. 4763 4764 The coefficients can be used for plane leveling using relation 4765 data[i] := data[i] - (pa + pby*i + pbx*j); 4766 4767 @param pa: Where constant coefficient should be stored (or B{C{NULL}}). I{(float)} 4768 @param pbx: Where x plane coefficient should be stored (or B{C{NULL}}). I{(float)} 4769 @param pby: Where y plane coefficient should be stored (or B{C{NULL}}). I{(float)} 4770 @return: 4771 """ 4772 return None
4773 - def UNIMPLEMENTED_fit_facet_plane( mfield , masking , pa , pbx , pby ):
4774 """ 4775 Calculates the inclination of a plane close to the dominant plane in a data 4776 field. 4777 4778 The dominant plane is determined by taking into account larger local slopes 4779 with exponentially smaller weight. 4780 4781 This is the basis of so-called facet levelling algorithm. Usually, the 4782 plane found by this method is subtracted using L{DataField.plane_level}() 4783 and the entire process is repeated until it converges. A convergence 4784 criterion may be sufficiently small values of the x and y plane 4785 coefficients. Note that since L{DataField.plane_level}() uses pixel-based 4786 lateral coordinates, the coefficients must be divided by 4787 L{DataField.get_xmeasure}(data_field) and 4788 L{DataField.get_ymeasure}(data_field) to obtain physical plane 4789 coefficients. 4790 4791 Since: 2.37 4792 4793 @param mfield: Mask specifying which values to take into account/exclude, or B{C{NULL}}. I{(L{DataField})} 4794 @param masking: Masking mode to use. I{(MaskingType)} 4795 @param pa: Where constant coefficient should be stored (or B{C{NULL}}). I{(gdouble*)} 4796 @param pbx: Where x plane coefficient should be stored. I{(gdouble*)} 4797 @param pby: Where y plane coefficient should be stored. I{(gdouble*)} 4798 @return: B{C{True}} if any plane was actually fitted; B{C{False}} if there was an 4799 insufficient number of unmasked pixels. 4800 4801 4802 """ 4803 return None
4804 - def plane_level( a , bx , by ):
4805 """ 4806 Subtracts plane from a data field. 4807 4808 See L{DataField.fit_plane}() for details. 4809 4810 @param a: Constant coefficient. I{(float)} 4811 @param bx: X plane coefficient. I{(float)} 4812 @param by: Y plane coefficient. I{(float)} 4813 @return: 4814 """ 4815 return None
4816 - def plane_rotate( xangle , yangle , interpolation ):
4817 """ 4818 Performs rotation of plane along x and y axis. 4819 4820 @param xangle: Rotation angle in x direction (rotation along y axis, in radians). I{(float)} 4821 @param yangle: Rotation angle in y direction (rotation along x axis, in radians). I{(float)} 4822 @param interpolation: Interpolation type (can be only of two-point type). I{(InterpolationType)} 4823 @return: 4824 """ 4825 return None
4826 - def fit_lines( col , row , width , height , degree , exclude , orientation ):
4827 """ 4828 Independently levels profiles on each row/column in a data field. 4829 4830 Lines that have no intersection with area selected by B{C{ulcol}}, B{C{ulrow}}, 4831 B{C{brcol}}, B{C{brrow}} are always leveled as a whole. Lines that have intersection 4832 with selected area, are leveled using polynomial coefficients computed only 4833 from data inside (or outside for B{C{exclude}} = B{C{True}}) the area. 4834 4835 @param col: Upper-left column coordinate. I{(int)} 4836 @param row: Upper-left row coordinate. I{(int)} 4837 @param width: Area width (number of columns). I{(int)} 4838 @param height: Area height (number of rows). I{(int)} 4839 @param degree: Fitted polynomial degree. I{(int)} 4840 @param exclude: If B{C{True}}, outside of area selected by B{C{ulcol}}, B{C{ulrow}}, B{C{brcol}}, 4841 B{C{brrow}} will be used for polynomial coefficients computation, 4842 instead of inside. I{(bool)} 4843 @param orientation: Line orientation. I{(Orientation)} 4844 @return: 4845 """ 4846 return None
4847 - def fit_polynom( col_degree , row_degree , coeffs ):
4848 """ 4849 Fits a two-dimensional polynomial to a data field. 4850 4851 4852 @param col_degree: Degree of polynomial to fit column-wise (x-coordinate). I{(int)} 4853 @param row_degree: Degree of polynomial to fit row-wise (y-coordinate). I{(int)} 4854 @param coeffs: An array of size (B{C{row_degree}}+1)*(B{C{col_degree}}+1) to store the 4855 coefficients to, or B{C{NULL}} (a fresh array is allocated then), 4856 see L{DataField.area_fit_polynom}() for details. I{(gdouble*)} 4857 @return: Either B{C{coeffs}} if it was not B{C{NULL}}, or a newly allocated array 4858 with coefficients. 4859 4860 """ 4861 return None
4862 - def area_fit_polynom( col , row , width , height , col_degree , row_degree , coeffs ):
4863 """ 4864 Fits a two-dimensional polynomial to a rectangular part of a data field. 4865 4866 The coefficients are stored by row into B{C{coeffs}}, like data in a datafield. 4867 Row index is y-degree, column index is x-degree. 4868 4869 Note naive x^n y^m polynomial fitting is numerically unstable, therefore 4870 this method works only up to B{C{col_degree}} = B{C{row_degree}} = 6. 4871 4872 4873 @param col: Upper-left column coordinate. I{(int)} 4874 @param row: Upper-left row coordinate. I{(int)} 4875 @param width: Area width (number of columns). I{(int)} 4876 @param height: Area height (number of rows). I{(int)} 4877 @param col_degree: Degree of polynomial to fit column-wise (x-coordinate). I{(int)} 4878 @param row_degree: Degree of polynomial to fit row-wise (y-coordinate). I{(int)} 4879 @param coeffs: An array of size (B{C{row_degree}}+1)*(B{C{col_degree}}+1) to store the 4880 coefficients to, or B{C{NULL}} (a fresh array is allocated then). I{(gdouble*)} 4881 @return: Either B{C{coeffs}} if it was not B{C{NULL}}, or a newly allocated array 4882 with coefficients. 4883 4884 """ 4885 return None
4886 - def subtract_polynom( col_degree , row_degree , coeffs ):
4887 """ 4888 Subtracts a two-dimensional polynomial from a data field. 4889 4890 @param col_degree: Degree of polynomial to subtract column-wise (x-coordinate). I{(int)} 4891 @param row_degree: Degree of polynomial to subtract row-wise (y-coordinate). I{(int)} 4892 @param coeffs: An array of size (B{C{row_degree}}+1)*(B{C{col_degree}}+1) with coefficients, 4893 see L{DataField.area_fit_polynom}() for details. I{(const-gdouble*)} 4894 @return: 4895 """ 4896 return None
4897 - def area_subtract_polynom( col , row , width , height , col_degree , row_degree , coeffs ):
4898 """ 4899 Subtracts a two-dimensional polynomial from a rectangular part of a data 4900 field. 4901 4902 @param col: Upper-left column coordinate. I{(int)} 4903 @param row: Upper-left row coordinate. I{(int)} 4904 @param width: Area width (number of columns). I{(int)} 4905 @param height: Area height (number of rows). I{(int)} 4906 @param col_degree: Degree of polynomial to subtract column-wise (x-coordinate). I{(int)} 4907 @param row_degree: Degree of polynomial to subtract row-wise (y-coordinate). I{(int)} 4908 @param coeffs: An array of size (B{C{row_degree}}+1)*(B{C{col_degree}}+1) with coefficients, 4909 see L{DataField.area_fit_polynom}() for details. I{(const-gdouble*)} 4910 @return: 4911 """ 4912 return None
4913 - def UNIMPLEMENTED_fit_legendre( col_degree , row_degree , coeffs ):
4914 """ 4915 Fits two-dimensional Legendre polynomial to a data field. 4916 4917 See L{DataField.area_fit_legendre}() for details. 4918 4919 4920 @param col_degree: Degree of polynomial to fit column-wise (x-coordinate). I{(int)} 4921 @param row_degree: Degree of polynomial to fit row-wise (y-coordinate). I{(int)} 4922 @param coeffs: An array of size (B{C{row_degree}}+1)*(B{C{col_degree}}+1) to store the 4923 coefficients to, or B{C{NULL}} (a fresh array is allocated then). I{(gdouble*)} 4924 @return: Either B{C{coeffs}} if it was not B{C{NULL}}, or a newly allocated array 4925 with coefficients. 4926 4927 """ 4928 return None
4929 - def UNIMPLEMENTED_area_fit_legendre( col , row , width , height , col_degree , row_degree , coeffs ):
4930 """ 4931 Fits two-dimensional Legendre polynomial to a rectangular part of a data 4932 field. 4933 4934 The B{C{col_degree}} and B{C{row_degree}} parameters limit the maximum powers of x and 4935 y exactly as if simple powers were fitted, therefore if you do not intend to 4936 interpret contents of B{C{coeffs}} youself, the only difference is that this 4937 method is much more numerically stable. 4938 4939 The coefficients are organized exactly like in 4940 L{DataField.area_fit_polynom}(), but they are not coefficients of 4941 x^n y^m, instead they are coefficients of P_n(x) P_m(x), where P are 4942 Legendre polynomials. The polynomials are evaluated in coordinates where 4943 first row (column) corresponds to -1.0, and the last row (column) to 1.0. 4944 4945 Note the polynomials are normal Legendre polynomials that are not exactly 4946 orthogonal on a discrete point set (if their degrees are equal mod 2). 4947 4948 4949 @param col: Upper-left column coordinate. I{(int)} 4950 @param row: Upper-left row coordinate. I{(int)} 4951 @param width: Area width (number of columns). I{(int)} 4952 @param height: Area height (number of rows). I{(int)} 4953 @param col_degree: Degree of polynomial to fit column-wise (x-coordinate). I{(int)} 4954 @param row_degree: Degree of polynomial to fit row-wise (y-coordinate). I{(int)} 4955 @param coeffs: An array of size (B{C{row_degree}}+1)*(B{C{col_degree}}+1) to store the 4956 coefficients to, or B{C{NULL}} (a fresh array is allocated then). I{(gdouble*)} 4957 @return: Either B{C{coeffs}} if it was not B{C{NULL}}, or a newly allocated array 4958 with coefficients. 4959 4960 """ 4961 return None
4962 - def subtract_legendre( col_degree , row_degree , coeffs ):
4963 """ 4964 Subtracts a two-dimensional Legendre polynomial fit from a data field. 4965 4966 @param col_degree: Degree of polynomial to subtract column-wise (x-coordinate). I{(int)} 4967 @param row_degree: Degree of polynomial to subtract row-wise (y-coordinate). I{(int)} 4968 @param coeffs: An array of size (B{C{row_degree}}+1)*(B{C{col_degree}}+1) with coefficients, 4969 see L{DataField.area_fit_legendre}() for details. I{(const-gdouble*)} 4970 @return: 4971 """ 4972 return None
4973 - def area_subtract_legendre( col , row , width , height , col_degree , row_degree , coeffs ):
4974 """ 4975 Subtracts a two-dimensional Legendre polynomial fit from a rectangular part 4976 of a data field. 4977 4978 Due to the transform of coordinates to [-1,1] x [-1,1], this method can be 4979 used on an area of dimensions different than the area the coefficients were 4980 calculated for. 4981 4982 @param col: Upper-left column coordinate. I{(int)} 4983 @param row: Upper-left row coordinate. I{(int)} 4984 @param width: Area width (number of columns). I{(int)} 4985 @param height: Area height (number of rows). I{(int)} 4986 @param col_degree: Degree of polynomial to subtract column-wise (x-coordinate). I{(int)} 4987 @param row_degree: Degree of polynomial to subtract row-wise (y-coordinate). I{(int)} 4988 @param coeffs: An array of size (B{C{row_degree}}+1)*(B{C{col_degree}}+1) with coefficients, 4989 see L{DataField.area_fit_legendre}() for details. I{(const-gdouble*)} 4990 @return: 4991 """ 4992 return None
4993 - def UNIMPLEMENTED_fit_poly_max( max_degree , coeffs ):
4994 """ 4995 Fits two-dimensional polynomial with limited total degree to a data field. 4996 4997 See L{DataField.area_fit_poly_max}() for details. 4998 4999 5000 @param max_degree: Maximum total polynomial degree, that is the maximum of m+n 5001 in x^n y^m terms. I{(int)} 5002 @param coeffs: An array of size (B{C{max_degree}}+1)*(B{C{max_degree}}+2)/2 to store the 5003 coefficients to, or B{C{NULL}} (a fresh array is allocated then). I{(gdouble*)} 5004 @return: Either B{C{coeffs}} if it was not B{C{NULL}}, or a newly allocated array 5005 with coefficients. 5006 5007 """ 5008 return None
5009 - def UNIMPLEMENTED_area_fit_poly_max( col , row , width , height , max_degree , coeffs ):
5010 """ 5011 Fits two-dimensional polynomial with limited total degree to a rectangular 5012 part of a data field. 5013 5014 See L{DataField.area_fit_legendre}() for description. This function 5015 differs by limiting the total maximum degree, while 5016 L{DataField.area_fit_legendre}() limits the maximum degrees in horizontal 5017 and vertical directions independently. 5018 5019 5020 @param col: Upper-left column coordinate. I{(int)} 5021 @param row: Upper-left row coordinate. I{(int)} 5022 @param width: Area width (number of columns). I{(int)} 5023 @param height: Area height (number of rows). I{(int)} 5024 @param max_degree: Maximum total polynomial degree, that is the maximum of m+n 5025 in x^n y^m terms. I{(int)} 5026 @param coeffs: An array of size (B{C{max_degree}}+1)*(B{C{max_degree}}+2)/2 to store the 5027 coefficients to, or B{C{NULL}} (a fresh array is allocated then). I{(gdouble*)} 5028 @return: Either B{C{coeffs}} if it was not B{C{NULL}}, or a newly allocated array 5029 with coefficients. 5030 5031 """ 5032 return None
5033 - def subtract_poly_max( max_degree , coeffs ):
5034 """ 5035 Subtracts a two-dimensional polynomial with limited total degree from 5036 a data field. 5037 5038 @param max_degree: Maximum total polynomial degree, that is the maximum of m+n 5039 in x^n y^m terms. I{(int)} 5040 @param coeffs: An array of size (B{C{row_degree}}+1)*(B{C{col_degree}}+2)/2 with 5041 coefficients, see L{DataField.area_fit_poly_max}() for details. I{(const-gdouble*)} 5042 @return: 5043 """ 5044 return None
5045 - def area_subtract_poly_max( col , row , width , height , max_degree , coeffs ):
5046 """ 5047 Subtracts a two-dimensional polynomial with limited total degree from a 5048 rectangular part of a data field. 5049 5050 Due to the transform of coordinates to [-1,1] x [-1,1], this method can be 5051 used on an area of dimensions different than the area the coefficients were 5052 calculated for. 5053 5054 @param col: Upper-left column coordinate. I{(int)} 5055 @param row: Upper-left row coordinate. I{(int)} 5056 @param width: Area width (number of columns). I{(int)} 5057 @param height: Area height (number of rows). I{(int)} 5058 @param max_degree: Maximum total polynomial degree, that is the maximum of m+n 5059 in x^n y^m terms. I{(int)} 5060 @param coeffs: An array of size (B{C{row_degree}}+1)*(B{C{col_degree}}+2)/2 with 5061 coefficients, see L{DataField.area_fit_poly_max}() for details. I{(const-gdouble*)} 5062 @return: 5063 """ 5064 return None
5065 - def fit_poly( mask_field , nterms , term_powers , exclude , coeffs ):
5066 """ 5067 Fit a given set of polynomial terms to a data field. 5068 5069 Since: 2.11 5070 5071 @param mask_field: Mask of values to take values into account, or B{C{NULL}} for full 5072 B{C{data_field}}. Values equal to 0.0 and below cause corresponding 5073 B{C{data_field}} samples to be ignored, values equal to 1.0 and above 5074 cause inclusion of corresponding B{C{data_field}} samples. The behaviour 5075 for values inside (0.0, 1.0) is undefined (it may be specified 5076 in the future). I{(L{DataField})} 5077 @param nterms: The number of polynomial terms to take into account (half the 5078 number of items in B{C{term_powers}}). I{(int)} 5079 @param term_powers: Array of size 2*B{C{nterms}} describing the terms to fit. Each 5080 terms is described by a couple of powers (powerx, powery). I{(const-gint*)} 5081 @param exclude: Interpret values B{C{w}} in the mask as 1.0-B{C{w}}. I{(bool)} 5082 @param coeffs: Array of size B{C{nterms}} to store the coefficients to, or B{C{NULL}} to 5083 allocate a new array. I{(gdouble*)} 5084 @return: Either B{C{coeffs}} if it was not B{C{NULL}}, or a newly allocated array 5085 with coefficients. 5086 5087 5088 """ 5089 return None
5090 - def area_fit_poly( mask_field , col , row , width , height , nterms , term_powers , exclude , coeffs ):
5091 """ 5092 Fit a given set of polynomial terms to a rectangular part of a data field. 5093 5094 The polynomial coefficients correspond to normalized coordinates that 5095 are always from the interval [-1,1] where -1 corresponds to the left/topmost 5096 pixel and 1 corresponds to the bottom/rightmost pixel of the area. 5097 5098 Since: 2.11 5099 5100 @param mask_field: Mask of values to take values into account, or B{C{NULL}} for full 5101 B{C{data_field}}. Values equal to 0.0 and below cause corresponding 5102 B{C{data_field}} samples to be ignored, values equal to 1.0 and above 5103 cause inclusion of corresponding B{C{data_field}} samples. The behaviour 5104 for values inside (0.0, 1.0) is undefined (it may be specified 5105 in the future). I{(L{DataField})} 5106 @param col: Upper-left column coordinate. I{(int)} 5107 @param row: Upper-left row coordinate. I{(int)} 5108 @param width: Area width (number of columns). I{(int)} 5109 @param height: Area height (number of rows). I{(int)} 5110 @param nterms: The number of polynomial terms to take into account (half the 5111 number of items in B{C{term_powers}}). I{(int)} 5112 @param term_powers: Array of size 2*B{C{nterms}} describing the terms to fit. Each 5113 terms is described by a couple of powers (powerx, powery). I{(const-gint*)} 5114 @param exclude: Interpret values B{C{w}} in the mask as 1.0-B{C{w}}. I{(bool)} 5115 @param coeffs: Array of size B{C{nterms}} to store the coefficients to, or B{C{NULL}} to 5116 allocate a new array. I{(gdouble*)} 5117 @return: Either B{C{coeffs}} if it was not B{C{NULL}}, or a newly allocated array 5118 with coefficients. 5119 5120 5121 """ 5122 return None
5123 - def subtract_poly( nterms , term_powers , coeffs ):
5124 """ 5125 Subtract a given set of polynomial terms from a data field. 5126 5127 Since: 2.11 5128 5129 @param nterms: The number of polynomial terms to take into account (half the 5130 number of items in B{C{term_powers}}). I{(int)} 5131 @param term_powers: Array of size 2*B{C{nterms}} describing the fitter terms. Each 5132 terms is described by a couple of powers (powerx, powery). I{(const-gint*)} 5133 @param coeffs: Array of size B{C{nterms}} to store with the coefficients. I{(const-gdouble*)} 5134 @return: 5135 """ 5136 return None
5137 - def area_subtract_poly( col , row , width , height , nterms , term_powers , coeffs ):
5138 """ 5139 Subtract a given set of polynomial terms from a rectangular part of a data 5140 field. 5141 5142 Since: 2.11 5143 5144 @param col: Upper-left column coordinate. I{(int)} 5145 @param row: Upper-left row coordinate. I{(int)} 5146 @param width: Area width (number of columns). I{(int)} 5147 @param height: Area height (number of rows). I{(int)} 5148 @param nterms: The number of polynomial terms to take into account (half the 5149 number of items in B{C{term_powers}}). I{(int)} 5150 @param term_powers: Array of size 2*B{C{nterms}} describing the fitted terms. Each 5151 terms is described by a couple of powers (powerx, powery). I{(const-gint*)} 5152 @param coeffs: Array of size B{C{nterms}} to store with the coefficients. I{(const-gdouble*)} 5153 @return: 5154 """ 5155 return None
5156 - def UNIMPLEMENTED_area_fit_local_planes( size , col , row , width , height , nresults , types , results ):
5157 """ 5158 Fits a plane through neighbourhood of each sample in a rectangular part 5159 of a data field. 5160 5161 The sample is always in the origin of its local (x,y) coordinate system, 5162 even if the neighbourhood is not centered about it (e.g. because sample 5163 is on the edge of data field). Z-coordinate is however not centered, 5164 that is B{C{PLANE_FIT_A}} is normal mean value. 5165 5166 5167 @param size: Neighbourhood size (must be at least 2). It is centered around 5168 each pixel, unless B{C{size}} is even when it sticks to the right. I{(int)} 5169 @param col: Upper-left column coordinate. I{(int)} 5170 @param row: Upper-left row coordinate. I{(int)} 5171 @param width: Area width (number of columns). I{(int)} 5172 @param height: Area height (number of rows). I{(int)} 5173 @param nresults: The number of requested quantities. I{(int)} 5174 @param types: The types of requested quantities. I{(const-PlaneFitQuantity*)} 5175 @param results: An array to store quantities to, may be B{C{NULL}} to allocate a new 5176 one which must be freed by caller then. If any item is B{C{NULL}}, 5177 a new data field is allocated for it, existing data fields 5178 are resized to B{C{width}} x B{C{height}}. I{(DataField**)} 5179 @return: An array of data fields with requested quantities, that is 5180 B{C{results}} unless it was B{C{NULL}} and a new array was allocated. 5181 5182 """ 5183 return None
5184 - def area_local_plane_quantity( size , col , row , width , height , type , result ):
5185 """ 5186 Convenience function to get just one quantity from 5187 L{DataField.area_fit_local_planes}(). 5188 5189 5190 @param size: Neighbourhood size. I{(int)} 5191 @param col: Upper-left column coordinate. I{(int)} 5192 @param row: Upper-left row coordinate. I{(int)} 5193 @param width: Area width (number of columns). I{(int)} 5194 @param height: Area height (number of rows). I{(int)} 5195 @param type: The type of requested quantity. I{(PlaneFitQuantity)} 5196 @param result: A data field to store result to, or B{C{NULL}} to allocate a new one. I{(L{DataField})} 5197 @return: B{C{result}} if it isn't B{C{NULL}}, otherwise a newly allocated data field. 5198 5199 """ 5200 return None
5201 - def UNIMPLEMENTED_fit_local_planes( size , nresults , types , results ):
5202 """ 5203 Fits a plane through neighbourhood of each sample in a data field. 5204 5205 See L{DataField.area_fit_local_planes}() for details. 5206 5207 5208 @param size: Neighbourhood size. I{(int)} 5209 @param nresults: The number of requested quantities. I{(int)} 5210 @param types: The types of requested quantities. I{(const-PlaneFitQuantity*)} 5211 @param results: An array to store quantities to. I{(DataField**)} 5212 @return: An array of data fields with requested quantities. 5213 5214 """ 5215 return None
5216 - def local_plane_quantity( size , type , result ):
5217 """ 5218 Convenience function to get just one quantity from 5219 L{DataField.fit_local_planes}(). 5220 5221 5222 @param size: Neighbourhood size. I{(int)} 5223 @param type: The type of requested quantity. I{(PlaneFitQuantity)} 5224 @param result: A data field to store result to, or B{C{NULL}} to allocate a new one. I{(L{DataField})} 5225 @return: B{C{result}} if it isn't B{C{NULL}}, otherwise a newly allocated data field. 5226 5227 """ 5228 return None
5229 - def get_max( ):
5230 """ 5231 Finds the maximum value of a data field. 5232 5233 This quantity is cached. 5234 5235 5236 @return: The maximum value. 5237 5238 """ 5239 return None
5240 - def get_min( ):
5241 """ 5242 Finds the minimum value of a data field. 5243 5244 This quantity is cached. 5245 5246 5247 @return: The minimum value. 5248 5249 """ 5250 return None
5251 - def get_min_max( min , max ):
5252 """ 5253 Finds minimum and maximum values of a data field. 5254 5255 @param min: Location to store minimum to. I{(float)} 5256 @param max: Location to store maximum to. I{(float)} 5257 @return: 5258 """ 5259 return None
5260 - def get_avg( ):
5261 """ 5262 Computes average value of a data field. 5263 5264 This quantity is cached. 5265 5266 5267 @return: The average value. 5268 5269 """ 5270 return None
5271 - def get_rms( ):
5272 """ 5273 Computes root mean square value of a data field. 5274 5275 This quantity is cached. 5276 5277 5278 @return: The root mean square value. 5279 5280 """ 5281 return None
5282 - def get_sum( ):
5283 """ 5284 Sums all values in a data field. 5285 5286 This quantity is cached. 5287 5288 5289 @return: The sum of all values. 5290 5291 """ 5292 return None
5293 - def get_median( ):
5294 """ 5295 Computes median value of a data field. 5296 5297 This quantity is cached. 5298 5299 5300 @return: The median value. 5301 5302 """ 5303 return None
5304 - def get_surface_area( ):
5305 """ 5306 Computes surface area of a data field. 5307 5308 This quantity is cached. 5309 5310 5311 @return: The surface area. 5312 5313 """ 5314 return None
5315 - def get_variation( ):
5316 """ 5317 Computes the total variation of a data field. 5318 5319 See L{DataField.area_get_variation}() for the definition. 5320 5321 This quantity is cached. 5322 5323 Since: 2.38 5324 5325 @return: The variation. 5326 5327 5328 """ 5329 return None
5330 - def get_entropy( ):
5331 """ 5332 Computes the entropy of a data field. 5333 5334 See L{DataField.area_get_entropy}() for the definition. 5335 5336 This quantity is cached. 5337 5338 Since: 2.42 5339 5340 @return: The value distribution entropy. 5341 5342 5343 """ 5344 return None
5345 - def get_entropy_2d( yfield ):
5346 """ 5347 Computes the entropy of a two-dimensional point cloud. 5348 5349 Each pair of corresponding B{C{xfield}} and B{C{yfield}} pixels is assumed to 5350 represent the coordinates (B{C{x}},B{C{y}}) of a point in plane. Hence they must have 5351 the same dimensions. 5352 5353 Since: 2.44 5354 5355 @param yfield: A data field containing the B{C{y}}-coordinates. I{(L{DataField})} 5356 @return: The two-dimensional distribution entropy. 5357 5358 5359 """ 5360 return None
5361 - def area_get_max( mask , col , row , width , height ):
5362 """ 5363 Finds the maximum value in a rectangular part of a data field. 5364 5365 5366 @param mask: Mask specifying which values to take into account/exclude, or B{C{NULL}}. I{(L{DataField})} 5367 @param col: Upper-left column coordinate. I{(int)} 5368 @param row: Upper-left row coordinate. I{(int)} 5369 @param width: Area width (number of columns). I{(int)} 5370 @param height: Area height (number of rows). I{(int)} 5371 @return: The maximum value. When the number of samples to calculate 5372 maximum of is zero, -B{C{G_MAXDOUBLE}} is returned. 5373 5374 """ 5375 return None
5376 - def area_get_min( mask , col , row , width , height ):
5377 """ 5378 Finds the minimum value in a rectangular part of a data field. 5379 5380 5381 @param mask: Mask specifying which values to take into account/exclude, or B{C{NULL}}. I{(L{DataField})} 5382 @param col: Upper-left column coordinate. I{(int)} 5383 @param row: Upper-left row coordinate. I{(int)} 5384 @param width: Area width (number of columns). I{(int)} 5385 @param height: Area height (number of rows). I{(int)} 5386 @return: The minimum value. When the number of samples to calculate 5387 minimum of is zero, -B{C{G_MAXDOUBLE}} is returned. 5388 5389 """ 5390 return None
5391 - def UNIMPLEMENTED_area_get_min_max( mask , col , row , width , height , min , max ):
5392 """ 5393 Finds minimum and maximum values in a rectangular part of a data field. 5394 5395 This function is equivalent to calling 5396 B{C{L{DataField.area_get_min_max_mask}}}() 5397 with masking mode B{C{MASK_INCLUDE}}. 5398 5399 @param mask: Mask specifying which values to take into account/exclude, or B{C{NULL}}. I{(L{DataField})} 5400 @param col: Upper-left column coordinate. I{(int)} 5401 @param row: Upper-left row coordinate. I{(int)} 5402 @param width: Area width (number of columns). I{(int)} 5403 @param height: Area height (number of rows). I{(int)} 5404 @param min: Location to store minimum to. I{(gdouble*)} 5405 @param max: Location to store maximum to. I{(gdouble*)} 5406 @return: 5407 """ 5408 return None
5409 - def UNIMPLEMENTED_area_get_min_max_mask( mask , mode , col , row , width , height , min , max ):
5410 """ 5411 Finds minimum and maximum values in a rectangular part of a data field. 5412 5413 Since: 2.18 5414 5415 @param mask: Mask specifying which values to take into account/exclude, or B{C{NULL}}. I{(L{DataField})} 5416 @param mode: Masking mode to use. See the introduction for description of 5417 masking modes. I{(MaskingType)} 5418 @param col: Upper-left column coordinate. I{(int)} 5419 @param row: Upper-left row coordinate. I{(int)} 5420 @param width: Area width (number of columns). I{(int)} 5421 @param height: Area height (number of rows). I{(int)} 5422 @param min: Location to store minimum to. I{(gdouble*)} 5423 @param max: Location to store maximum to. I{(gdouble*)} 5424 @return: 5425 """ 5426 return None
5427 - def area_get_avg( mask , col , row , width , height ):
5428 """ 5429 Computes average value of a rectangular part of a data field. 5430 5431 This function is equivalent to calling B{C{L{DataField.area_get_avg_mask}}}() 5432 with masking mode B{C{MASK_INCLUDE}}. 5433 5434 5435 @param mask: Mask specifying which values to take into account/exclude, or B{C{NULL}}. I{(L{DataField})} 5436 @param col: Upper-left column coordinate. I{(int)} 5437 @param row: Upper-left row coordinate. I{(int)} 5438 @param width: Area width (number of columns). I{(int)} 5439 @param height: Area height (number of rows). I{(int)} 5440 @return: The average value. 5441 5442 """ 5443 return None
5444 - def area_get_avg_mask( mask , mode , col , row , width , height ):
5445 """ 5446 Computes average value of a rectangular part of a data field. 5447 5448 Since: 2.18 5449 5450 @param mask: Mask specifying which values to take into account/exclude, or B{C{NULL}}. I{(L{DataField})} 5451 @param mode: Masking mode to use. See the introduction for description of 5452 masking modes. I{(MaskingType)} 5453 @param col: Upper-left column coordinate. I{(int)} 5454 @param row: Upper-left row coordinate. I{(int)} 5455 @param width: Area width (n