aghh what is with cocoa's bitmap loading

Post: #1
whenever i run code which loads a bitmap into opengl memory using cocoa's NSBitmapImageRep class, then quit the program, then either change the image file (ex. replacing it with another image, or simply deleting it), and run the code again it acts like the file is exactly the same as it was when the code was run for the first time. this is VERY annoying, and has happened to me on multiple occasions. i was just wondering whether this has happened to anyone else, and what they did to fix it.
Quote this message in a reply
Posts: 608
Joined: 2002.04
Post: #2
Chances are you need to clean your project after changing the image.
Quote this message in a reply
Posts: 177
Joined: 2002.08
Post: #3
Yes, it's probably loading from a copy of the image inside the app bundle that was put there by the build process.
Quote this message in a reply
Post: #4
So, just rebuild your project - you shouldn't need to clean it...
Quote this message in a reply
Posts: 5,143
Joined: 2002.04
Post: #5
If the file is a resource inside a folder reference, PB won't check if it's been updated. It's an annoying bug, but Jabber's right that the fix is to clean the project (removing the executable from the build folder works too).
Quote this message in a reply
Post: #6
Oh, ok. That's a bit poor...
Quote this message in a reply
Post Reply 

Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Bitmap fonts markhula 6 7,568 Feb 27, 2011 12:55 PM
Last Post: markhula
  Bitmap font toolkit Najdorf 9 6,495 Nov 11, 2008 05:43 PM
Last Post: Najdorf
  Bitmap Fonts in GL Joseph Duchesne 18 9,037 Feb 3, 2006 09:25 AM
Last Post: ThemsAllTook
  obtaining bitmap data from jpg file with odd size isyuwono 2 2,063 Jan 26, 2006 11:45 AM
Last Post: zKing
  Question about displaying a bitmap while drawing other stuff on top of it Malarkey 4 2,842 May 1, 2005 10:39 PM
Last Post: Malarkey