User-agent: Mozilla Thunderbird 1.0.2 (Macintosh/20050317)
Hello,
I tried both methods and they work for me.
> Method 1:
> Use malloc( ) to allocate a big chunk(about 22M) of buffer to keep data.
Here's part of my code:
rasterDataIn = (Ptr) malloc ( pageWidth * pageHeight * 4 );
rasterDataPtr = rasterDataIn;
Then for each band:
memcpy (rasterDataPtr, pmRasterBand.baseAddress, pmRasterBand.size);
rasterDataPtr += pmRasterBand.size;
> Method 2:
> Try to create a file to keep data like below shown. But I can't open
> it. In other directory, like /usr/lib,using the open function to test is
> okay. It looks like permission problem. But I don't know how to solve in
> printer driver.
>
> Tempfd =open("ExpRaster.dump", O_RDWR | O_CREAT, S_IRWXU | S_IRWXG |
> S_IRWXO);
Try this:
Tempfd =open("ExpRaster.dump", O_CREAT | O_WRONLY, 0644);
Regards
--
Xavier Garreau <email@hidden>
http://www.xgarreau.org/
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Printing mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/printing/email@hidden
This email sent to email@hidden