OLD | NEW |
1 #ifndef __DEFINED__SkPdfType0FunctionDictionary | 1 #ifndef __DEFINED__SkPdfType0FunctionDictionary |
2 #define __DEFINED__SkPdfType0FunctionDictionary | 2 #define __DEFINED__SkPdfType0FunctionDictionary |
3 | 3 |
4 #include "SkPdfUtils.h" | 4 #include "SkPdfUtils.h" |
5 #include "SkPdfEnums_autogen.h" | 5 #include "SkPdfEnums_autogen.h" |
6 #include "SkPdfArray_autogen.h" | 6 #include "SkPdfArray_autogen.h" |
7 #include "SkPdfDictionary_autogen.h" | 7 #include "SkPdfDictionary_autogen.h" |
8 | 8 |
9 // Additional entries specific to a type 0 function dictionary | 9 // Additional entries specific to a type 0 function dictionary |
10 class SkPdfType0FunctionDictionary : public SkPdfDictionary { | 10 class SkPdfType0FunctionDictionary : public SkPdfDictionary { |
(...skipping 514 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
525 | 525 |
526 SkPdfType0FunctionDictionary& operator=(const SkPdfType0FunctionDictionary& fr
om) {this->fPodofoDoc = from.fPodofoDoc; this->fPodofoObj = from.fPodofoObj; ret
urn *this;} | 526 SkPdfType0FunctionDictionary& operator=(const SkPdfType0FunctionDictionary& fr
om) {this->fPodofoDoc = from.fPodofoDoc; this->fPodofoObj = from.fPodofoObj; ret
urn *this;} |
527 | 527 |
528 /** (Required) An array of m positive integers specifying the number of samples | 528 /** (Required) An array of m positive integers specifying the number of samples |
529 * in each input dimension of the sample table. | 529 * in each input dimension of the sample table. |
530 **/ | 530 **/ |
531 bool has_Size() const { | 531 bool has_Size() const { |
532 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Size"
, "", NULL)); | 532 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Size"
, "", NULL)); |
533 } | 533 } |
534 | 534 |
535 SkPdfArray* Size() const { | 535 SkPdfArray* Size() const; |
536 SkPdfArray* ret; | |
537 if (ArrayFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Size", "",
&ret)) return ret; | |
538 // TODO(edisonn): warn about missing required field, assert for known good p
dfs | |
539 return NULL; | |
540 } | |
541 | |
542 /** (Required) The number of bits used to represent each sample. (If the functio
n | 536 /** (Required) The number of bits used to represent each sample. (If the functio
n |
543 * has multiple output values, each one occupies BitsPerSample bits.) Valid | 537 * has multiple output values, each one occupies BitsPerSample bits.) Valid |
544 * values are 1, 2, 4, 8, 12, 16, 24, and 32. | 538 * values are 1, 2, 4, 8, 12, 16, 24, and 32. |
545 **/ | 539 **/ |
546 bool has_BitsPerSample() const { | 540 bool has_BitsPerSample() const { |
547 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "BitsP
erSample", "", NULL)); | 541 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "BitsP
erSample", "", NULL)); |
548 } | 542 } |
549 | 543 |
550 long BitsPerSample() const { | 544 long BitsPerSample() const; |
551 long ret; | |
552 if (LongFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "BitsPerSamp
le", "", &ret)) return ret; | |
553 // TODO(edisonn): warn about missing required field, assert for known good p
dfs | |
554 return 0; | |
555 } | |
556 | |
557 /** (Optional) The order of interpolation between samples. Valid values are 1 | 545 /** (Optional) The order of interpolation between samples. Valid values are 1 |
558 * and 3, specifying linear and cubic spline interpolation, respectively. (See
im- | 546 * and 3, specifying linear and cubic spline interpolation, respectively. (See
im- |
559 * plementation note 26 in Appendix H.) Default value: 1. | 547 * plementation note 26 in Appendix H.) Default value: 1. |
560 **/ | 548 **/ |
561 bool has_Order() const { | 549 bool has_Order() const { |
562 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Order
", "", NULL)); | 550 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Order
", "", NULL)); |
563 } | 551 } |
564 | 552 |
565 long Order() const { | 553 long Order() const; |
566 long ret; | |
567 if (LongFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Order", "",
&ret)) return ret; | |
568 // TODO(edisonn): warn about missing required field, assert for known good p
dfs | |
569 return 0; | |
570 } | |
571 | |
572 /** (Optional) An array of 2 x m numbers specifying the linear mapping of input | 554 /** (Optional) An array of 2 x m numbers specifying the linear mapping of input |
573 * values into the domain of the function's sample table. Default value: | 555 * values into the domain of the function's sample table. Default value: |
574 * [0 (Size0 - 1) 0 (Size1 - 1) ...]. | 556 * [0 (Size0 - 1) 0 (Size1 - 1) ...]. |
575 **/ | 557 **/ |
576 bool has_Encode() const { | 558 bool has_Encode() const { |
577 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Encod
e", "", NULL)); | 559 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Encod
e", "", NULL)); |
578 } | 560 } |
579 | 561 |
580 SkPdfArray* Encode() const { | 562 SkPdfArray* Encode() const; |
581 SkPdfArray* ret; | |
582 if (ArrayFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Encode", "
", &ret)) return ret; | |
583 // TODO(edisonn): warn about missing required field, assert for known good p
dfs | |
584 return NULL; | |
585 } | |
586 | |
587 /** (Optional) An array of 2 x n numbers specifying the linear mapping of sam- | 563 /** (Optional) An array of 2 x n numbers specifying the linear mapping of sam- |
588 * ple values into the range appropriate for the function's output values. Defa
ult | 564 * ple values into the range appropriate for the function's output values. Defa
ult |
589 * value: same as the value of Range. | 565 * value: same as the value of Range. |
590 **/ | 566 **/ |
591 bool has_Decode() const { | 567 bool has_Decode() const { |
592 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Decod
e", "", NULL)); | 568 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Decod
e", "", NULL)); |
593 } | 569 } |
594 | 570 |
595 SkPdfArray* Decode() const { | 571 SkPdfArray* Decode() const; |
596 SkPdfArray* ret; | |
597 if (ArrayFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Decode", "
", &ret)) return ret; | |
598 // TODO(edisonn): warn about missing required field, assert for known good p
dfs | |
599 return NULL; | |
600 } | |
601 | |
602 }; | 572 }; |
603 | 573 |
604 #endif // __DEFINED__SkPdfType0FunctionDictionary | 574 #endif // __DEFINED__SkPdfType0FunctionDictionary |
OLD | NEW |