Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GetGraphicsImporterForDataRef



Keith,

I think you are OK, if you change one thing in your code. ;)

Change PointerDataHandlerSubType to HandleDataHandlerSubType in your call to
GetGraphicsImporterForDataRef(). You're not sending a Pointer, your're
sending a Handle as your data reference.


Scott Tury


On 9/8/02 1:00 AM, "email@hidden"
<email@hidden> wrote:

> data = [NSData dataWithContentsOfURL:url];
> dataref = NewHandle(sizeof(const void*));
> HLock(dataref);
> *(const void**)*dataref = [data bytes];
> HUnlock(dataref);
>
> err = GetGraphicsImporterForDataRef(dataref,
> PointerDataHandlerSubType, &gi);
> if (err != noErr)
> {
> NSLog(@"Can't get graphics import component for data");
> goto CLEAN_UP_SELF;
> }
_______________________________________________
mac-games-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/mac-games-dev
Do not post admin requests to the list. They will be ignored.



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.