KDZ Extract PICT image from Mac Resource?



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 24/06/2004 at 23:08, xxxxxxxx wrote:

    User Information:
    Cinema 4D Version:   8.503 
    Platform:   Windows  ;   
    Language(s) :     C++  ;

    ---------
    Sort of off topic as it were, but this is definitely not an easy task from what I've seen so far. Now THIS makes the C4D SDK look simple. So far, I've only found one source code that only reads PICT files, not MAC PICT resource files and it's so interdependent on its own code classes (dozens and dozens of sources and headers), it would take months just to extract the relevant parts (and it is copyrighted). For the curious, this is for showing Poser thumbnail images residing in .rsr files (which are MAC PICT resource fork files - most likely only bitmap type, not vector).

    I'll take a lib, source, psychological evaluation...

    "The Encyclopedia of Graphics File Formats" says, and I quote:

    ...the Macintosh PICT format is far too complex for us to do justice to it here...

    Not very encouraging considering that there are differences between the PICT format (like a 512 byte header) and the PICT resource (apparently no 512 byte header)!

    Help!!! :)

    Kuroyume



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 25/06/2004 at 00:05, xxxxxxxx wrote:

    I think that I have a stop-gap (and less hair-pulling) alternative. C4D seems to handle .pct (PICT) files well enough and have found the differences that can change the .rsr into a .pct file (on the fly). So, now I wish there was a delete topic button... ;)

    Thanks,
    Robert



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 25/06/2004 at 00:34, xxxxxxxx wrote:

    Not quite so successful. The temporary .pct file IS proper, but C4D is only showing an alpha where there should be colors (just the surrounding background color is shown). To verify that the temp image is proper, I've viewed it with the Quicktime Viewer and compared it to other .pct files. It is a valid .pct file. So, this leads me to believe that C4D (SDK) is not handling the .pct files properly.

    Remember that the image file is loaded into a BitmapButton using SetImage(filename, FALSE);

    Thanks,
    Robert



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 25/06/2004 at 11:27, xxxxxxxx wrote:

    Any ideas?

    Even Adobe Photoshop can read the temp .pct file... There are differences between 'native' .pct files and those in the .rsr files, but only after header information and before bitmap information which seems to be variable and possibly dependent on the writing software of the .pct file (that is, inserted; for instance, Adobe shows up in this section in some cases). Otherwise, it's seen as a valid PICT format but loads strangely in C4D. Any information on the format expectations supported by C4D?

    Thanks,
    Robert



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 25/06/2004 at 13:52, xxxxxxxx wrote:

    While I hate talking to myself ;), this may prove useful to someone at a later date, so I'll continue adding information as it arrives.

    C4D is having difficulties with the alpha channel on these (most likely ancient) PICT (v2) files. It is inverting the alpha channel so that what is seen should be alpha and what is not should have been visible. To correct this, I just removed the alpha channel. So you get a black background where the alpha really was, but you can see the color image. Could've just inverted the alpha pixels, but tis more time consuming and not very necessary. We'll see.

    Robert


Log in to reply