Lines Matching refs:image
189 Image *image,Image *inject_image,ExceptionInfo *exception) in Huffman2DEncodeImage() argument
219 if (WriteBlob(image,length,group4) != (ssize_t) length) in Huffman2DEncodeImage()
225 static MagickBooleanType WritePS2Image(const ImageInfo *image_info,Image *image, in WritePS2Image() argument
461 assert(image != (Image *) NULL); in WritePS2Image()
462 assert(image->signature == MagickCoreSignature); in WritePS2Image()
463 if (image->debug != MagickFalse) in WritePS2Image()
464 (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); in WritePS2Image()
467 status=OpenBlob(image_info,image,WriteBinaryBlobMode,exception); in WritePS2Image()
470 compression=image->compression; in WritePS2Image()
481 image->filename); in WritePS2Image()
491 imageListLength=GetImageListLength(image); in WritePS2Image()
499 resolution.x=image->resolution.x; in WritePS2Image()
500 resolution.y=image->resolution.y; in WritePS2Image()
517 if (image->units == PixelsPerCentimeterResolution) in WritePS2Image()
522 SetGeometry(image,&geometry); in WritePS2Image()
524 (double) image->columns,(double) image->rows); in WritePS2Image()
528 if ((image->page.width != 0) && (image->page.height != 0)) in WritePS2Image()
530 "%.20gx%.20g%+.20g%+.20g",(double) image->page.width,(double) in WritePS2Image()
531 image->page.height,(double) image->page.x,(double) image->page.y); in WritePS2Image()
533 if ((image->gravity != UndefinedGravity) && in WritePS2Image()
544 (void) ParseGravityGeometry(image,page_geometry,&page_info,exception); in WritePS2Image()
545 if (image->gravity != UndefinedGravity) in WritePS2Image()
548 geometry.y=(ssize_t) (media_info.height+page_info.y-image->rows); in WritePS2Image()
554 value=GetImageProperty(image,"label",exception); in WritePS2Image()
567 (void) WriteBlobString(image,buffer); in WritePS2Image()
568 (void) WriteBlobString(image,"%%Creator: (ImageMagick)\n"); in WritePS2Image()
570 image->filename); in WritePS2Image()
571 (void) WriteBlobString(image,buffer); in WritePS2Image()
576 (void) WriteBlobString(image,buffer); in WritePS2Image()
582 (GetNextImageInList(image) != (Image *) NULL)) in WritePS2Image()
590 (void) WriteBlobString(image,buffer); in WritePS2Image()
595 (void) WriteBlobString(image,buffer); in WritePS2Image()
596 value=GetImageProperty(image,"label",exception); in WritePS2Image()
598 (void) WriteBlobString(image, in WritePS2Image()
600 (void) WriteBlobString(image,"%%LanguageLevel: 2\n"); in WritePS2Image()
602 (void) WriteBlobString(image,"%%Pages: 1\n"); in WritePS2Image()
605 (void) WriteBlobString(image,"%%Orientation: Portrait\n"); in WritePS2Image()
606 (void) WriteBlobString(image,"%%PageOrder: Ascend\n"); in WritePS2Image()
612 (void) WriteBlobString(image,buffer); in WritePS2Image()
614 if (image->colorspace == CMYKColorspace) in WritePS2Image()
615 (void) WriteBlobString(image, in WritePS2Image()
617 (void) WriteBlobString(image,"%%EndComments\n"); in WritePS2Image()
618 (void) WriteBlobString(image,"\n%%BeginDefaults\n"); in WritePS2Image()
619 (void) WriteBlobString(image,"%%EndDefaults\n\n"); in WritePS2Image()
658 (void) WriteBlobString(image,buffer); in WritePS2Image()
659 (void) WriteBlobByte(image,'\n'); in WritePS2Image()
661 value=GetImageProperty(image,"label",exception); in WritePS2Image()
664 (void) WriteBlobString(image, in WritePS2Image()
668 (void) WriteBlobString(image," /label 512 string def\n"); in WritePS2Image()
669 (void) WriteBlobString(image, in WritePS2Image()
673 (void) WriteBlobString(image,buffer); in WritePS2Image()
679 (void) WriteBlobString(image,buffer); in WritePS2Image()
682 (void) WriteBlobString(image," showpage\n"); in WritePS2Image()
683 (void) WriteBlobString(image,"} bind def\n"); in WritePS2Image()
684 (void) WriteBlobString(image,"%%EndProlog\n"); in WritePS2Image()
688 (void) WriteBlobString(image,buffer); in WritePS2Image()
693 (void) WriteBlobString(image,buffer); in WritePS2Image()
702 value=GetImageProperty(image,"label",exception); in WritePS2Image()
704 (void) WriteBlobString(image,"%%PageResources: font Helvetica\n"); in WritePS2Image()
706 (void) WriteBlobString(image,"userdict begin\n"); in WritePS2Image()
707 start=TellBlob(image); in WritePS2Image()
711 (void) WriteBlobString(image,buffer); in WritePS2Image()
712 stop=TellBlob(image); in WritePS2Image()
713 (void) WriteBlobString(image,"DisplayImage\n"); in WritePS2Image()
720 (void) WriteBlobString(image,buffer); in WritePS2Image()
722 value=GetImageProperty(image,"label",exception); in WritePS2Image()
731 (void) WriteBlobString(image,buffer); in WritePS2Image()
736 number_pixels=(MagickSizeType) image->columns*image->rows; in WritePS2Image()
741 (SetImageGray(image,exception) != MagickFalse))) in WritePS2Image()
744 "%.20g %.20g\n1\n%d\n",(double) image->columns,(double) image->rows, in WritePS2Image()
745 (int) (image->colorspace == CMYKColorspace)); in WritePS2Image()
746 (void) WriteBlobString(image,buffer); in WritePS2Image()
750 (void) WriteBlobString(image,buffer); in WritePS2Image()
751 (void) WriteBlobString(image,"0\n"); in WritePS2Image()
755 (void) WriteBlobString(image,buffer); in WritePS2Image()
763 (void) HuffmanEncodeImage(image_info,image,image,exception); in WritePS2Image()
766 (void) Huffman2DEncodeImage(image_info,image,image,exception); in WritePS2Image()
771 status=InjectImageBlob(image_info,image,image,"jpeg",exception); in WritePS2Image()
774 (void) CloseBlob(image); in WritePS2Image()
800 for (y=0; y < (ssize_t) image->rows; y++) in WritePS2Image()
802 p=GetVirtualPixels(image,0,y,image->columns,1,exception); in WritePS2Image()
805 for (x=0; x < (ssize_t) image->columns; x++) in WritePS2Image()
807 *q++=ScaleQuantumToChar(ClampToQuantum(GetPixelLuma(image,p))); in WritePS2Image()
808 p+=GetPixelChannels(image); in WritePS2Image()
810 progress=SetImageProgress(image,SaveImageTag,(MagickOffsetType) y, in WritePS2Image()
811 image->rows); in WritePS2Image()
817 status=LZWEncodeImage(image,length,pixels,exception); in WritePS2Image()
819 status=PackbitsEncodeImage(image,length,pixels,exception); in WritePS2Image()
823 (void) CloseBlob(image); in WritePS2Image()
833 Ascii85Initialize(image); in WritePS2Image()
834 for (y=0; y < (ssize_t) image->rows; y++) in WritePS2Image()
836 p=GetVirtualPixels(image,0,y,image->columns,1,exception); in WritePS2Image()
839 for (x=0; x < (ssize_t) image->columns; x++) in WritePS2Image()
841 Ascii85Encode(image,ScaleQuantumToChar(ClampToQuantum( in WritePS2Image()
842 GetPixelLuma(image,p)))); in WritePS2Image()
843 p+=GetPixelChannels(image); in WritePS2Image()
845 progress=SetImageProgress(image,SaveImageTag,(MagickOffsetType) in WritePS2Image()
846 y,image->rows); in WritePS2Image()
850 Ascii85Flush(image); in WritePS2Image()
856 if ((image->storage_class == DirectClass) || (image->colors > 256) || in WritePS2Image()
857 (compression == JPEGCompression) || (image->alpha_trait != UndefinedPixelTrait)) in WritePS2Image()
860 "%.20g %.20g\n0\n%d\n",(double) image->columns,(double) image->rows, in WritePS2Image()
861 (int) (image->colorspace == CMYKColorspace)); in WritePS2Image()
862 (void) WriteBlobString(image,buffer); in WritePS2Image()
865 (void) WriteBlobString(image,buffer); in WritePS2Image()
870 status=InjectImageBlob(image_info,image,image,"jpeg",exception); in WritePS2Image()
873 (void) CloseBlob(image); in WritePS2Image()
900 for (y=0; y < (ssize_t) image->rows; y++) in WritePS2Image()
902 p=GetVirtualPixels(image,0,y,image->columns,1,exception); in WritePS2Image()
905 for (x=0; x < (ssize_t) image->columns; x++) in WritePS2Image()
907 if ((image->alpha_trait != UndefinedPixelTrait) && in WritePS2Image()
908 (GetPixelAlpha(image,p) == (Quantum) TransparentAlpha)) in WritePS2Image()
915 if (image->colorspace != CMYKColorspace) in WritePS2Image()
917 *q++=ScaleQuantumToChar(GetPixelRed(image,p)); in WritePS2Image()
918 *q++=ScaleQuantumToChar(GetPixelGreen(image,p)); in WritePS2Image()
919 *q++=ScaleQuantumToChar(GetPixelBlue(image,p)); in WritePS2Image()
923 *q++=ScaleQuantumToChar(GetPixelRed(image,p)); in WritePS2Image()
924 *q++=ScaleQuantumToChar(GetPixelGreen(image,p)); in WritePS2Image()
925 *q++=ScaleQuantumToChar(GetPixelBlue(image,p)); in WritePS2Image()
926 *q++=ScaleQuantumToChar(GetPixelBlack(image,p)); in WritePS2Image()
928 p+=GetPixelChannels(image); in WritePS2Image()
930 progress=SetImageProgress(image,SaveImageTag,(MagickOffsetType) in WritePS2Image()
931 y,image->rows); in WritePS2Image()
937 status=LZWEncodeImage(image,length,pixels,exception); in WritePS2Image()
939 status=PackbitsEncodeImage(image,length,pixels,exception); in WritePS2Image()
942 (void) CloseBlob(image); in WritePS2Image()
953 Ascii85Initialize(image); in WritePS2Image()
954 for (y=0; y < (ssize_t) image->rows; y++) in WritePS2Image()
956 p=GetVirtualPixels(image,0,y,image->columns,1,exception); in WritePS2Image()
959 for (x=0; x < (ssize_t) image->columns; x++) in WritePS2Image()
961 if ((image->alpha_trait != UndefinedPixelTrait) && in WritePS2Image()
962 (GetPixelAlpha(image,p) == (Quantum) TransparentAlpha)) in WritePS2Image()
964 Ascii85Encode(image,ScaleQuantumToChar((Quantum) in WritePS2Image()
966 Ascii85Encode(image,ScaleQuantumToChar((Quantum) in WritePS2Image()
968 Ascii85Encode(image,ScaleQuantumToChar((Quantum) in WritePS2Image()
972 if (image->colorspace != CMYKColorspace) in WritePS2Image()
974 Ascii85Encode(image,ScaleQuantumToChar( in WritePS2Image()
975 GetPixelRed(image,p))); in WritePS2Image()
976 Ascii85Encode(image,ScaleQuantumToChar( in WritePS2Image()
977 GetPixelGreen(image,p))); in WritePS2Image()
978 Ascii85Encode(image,ScaleQuantumToChar( in WritePS2Image()
979 GetPixelBlue(image,p))); in WritePS2Image()
983 Ascii85Encode(image,ScaleQuantumToChar( in WritePS2Image()
984 GetPixelRed(image,p))); in WritePS2Image()
985 Ascii85Encode(image,ScaleQuantumToChar( in WritePS2Image()
986 GetPixelGreen(image,p))); in WritePS2Image()
987 Ascii85Encode(image,ScaleQuantumToChar( in WritePS2Image()
988 GetPixelBlue(image,p))); in WritePS2Image()
989 Ascii85Encode(image,ScaleQuantumToChar( in WritePS2Image()
990 GetPixelBlack(image,p))); in WritePS2Image()
992 p+=GetPixelChannels(image); in WritePS2Image()
994 progress=SetImageProgress(image,SaveImageTag,(MagickOffsetType) in WritePS2Image()
995 y,image->rows); in WritePS2Image()
999 Ascii85Flush(image); in WritePS2Image()
1010 "%.20g %.20g\n1\n%d\n",(double) image->columns,(double) image->rows, in WritePS2Image()
1011 (int) (image->colorspace == CMYKColorspace)); in WritePS2Image()
1012 (void) WriteBlobString(image,buffer); in WritePS2Image()
1015 (void) WriteBlobString(image,buffer); in WritePS2Image()
1017 image->colors); in WritePS2Image()
1018 (void) WriteBlobString(image,buffer); in WritePS2Image()
1019 for (i=0; i < (ssize_t) image->colors; i++) in WritePS2Image()
1022 ScaleQuantumToChar(image->colormap[i].red), in WritePS2Image()
1023 ScaleQuantumToChar(image->colormap[i].green), in WritePS2Image()
1024 ScaleQuantumToChar(image->colormap[i].blue)); in WritePS2Image()
1025 (void) WriteBlobString(image,buffer); in WritePS2Image()
1051 for (y=0; y < (ssize_t) image->rows; y++) in WritePS2Image()
1053 p=GetVirtualPixels(image,0,y,image->columns,1,exception); in WritePS2Image()
1056 for (x=0; x < (ssize_t) image->columns; x++) in WritePS2Image()
1058 *q++=(unsigned char) GetPixelIndex(image,p); in WritePS2Image()
1059 p+=GetPixelChannels(image); in WritePS2Image()
1061 progress=SetImageProgress(image,SaveImageTag,(MagickOffsetType) in WritePS2Image()
1062 y,image->rows); in WritePS2Image()
1068 status=LZWEncodeImage(image,length,pixels,exception); in WritePS2Image()
1070 status=PackbitsEncodeImage(image,length,pixels,exception); in WritePS2Image()
1074 (void) CloseBlob(image); in WritePS2Image()
1084 Ascii85Initialize(image); in WritePS2Image()
1085 for (y=0; y < (ssize_t) image->rows; y++) in WritePS2Image()
1087 p=GetVirtualPixels(image,0,y,image->columns,1,exception); in WritePS2Image()
1090 for (x=0; x < (ssize_t) image->columns; x++) in WritePS2Image()
1092 Ascii85Encode(image,(unsigned char) GetPixelIndex(image,p)); in WritePS2Image()
1093 p+=GetPixelChannels(image); in WritePS2Image()
1095 progress=SetImageProgress(image,SaveImageTag,(MagickOffsetType) in WritePS2Image()
1096 y,image->rows); in WritePS2Image()
1100 Ascii85Flush(image); in WritePS2Image()
1105 (void) WriteBlobByte(image,'\n'); in WritePS2Image()
1106 length=(size_t) (TellBlob(image)-stop); in WritePS2Image()
1107 stop=TellBlob(image); in WritePS2Image()
1108 offset=SeekBlob(image,start,SEEK_SET); in WritePS2Image()
1114 (void) WriteBlobString(image,buffer); in WritePS2Image()
1115 offset=SeekBlob(image,stop,SEEK_SET); in WritePS2Image()
1116 (void) WriteBlobString(image,"%%EndData\n"); in WritePS2Image()
1118 (void) WriteBlobString(image,"end\n"); in WritePS2Image()
1119 (void) WriteBlobString(image,"%%PageTrailer\n"); in WritePS2Image()
1120 if (GetNextImageInList(image) == (Image *) NULL) in WritePS2Image()
1122 image=SyncNextImageInList(image); in WritePS2Image()
1123 status=SetImageProgress(image,SaveImagesTag,scene++,imageListLength); in WritePS2Image()
1127 (void) WriteBlobString(image,"%%Trailer\n"); in WritePS2Image()
1133 (void) WriteBlobString(image,buffer); in WritePS2Image()
1137 (void) WriteBlobString(image,buffer); in WritePS2Image()
1139 (void) WriteBlobString(image,"%%EOF\n"); in WritePS2Image()
1140 (void) CloseBlob(image); in WritePS2Image()