@@ -208,7 +208,7 @@ class Image : public ::Image {
208208 */
209209 void Load (const std::string& fileName) {
210210 set (::LoadImage (fileName.c_str ()));
211- if (!IsReady ()) {
211+ if (!IsValid ()) {
212212 throw RaylibException (" Failed to load Image from file: " + fileName);
213213 }
214214 }
@@ -222,7 +222,7 @@ class Image : public ::Image {
222222 */
223223 void Load (const std::string& fileName, int width, int height, int format, int headerSize) {
224224 set (::LoadImageRaw (fileName.c_str (), width, height, format, headerSize));
225- if (!IsReady ()) {
225+ if (!IsValid ()) {
226226 throw RaylibException (" Failed to load Image from file: " + fileName);
227227 }
228228 }
@@ -236,7 +236,7 @@ class Image : public ::Image {
236236 */
237237 void Load (const std::string& fileName, int * frames) {
238238 set (::LoadImageAnim (fileName.c_str (), frames));
239- if (!IsReady ()) {
239+ if (!IsValid ()) {
240240 throw RaylibException (" Failed to load Image from file: " + fileName);
241241 }
242242 }
@@ -250,7 +250,7 @@ class Image : public ::Image {
250250 */
251251 void Load (const std::string& fileType, const unsigned char * fileData, int dataSize) {
252252 set (::LoadImageFromMemory (fileType.c_str (), fileData, dataSize));
253- if (!IsReady ()) {
253+ if (!IsValid ()) {
254254 throw RaylibException (" Failed to load Image data with file type: " + fileType);
255255 }
256256 }
@@ -264,7 +264,7 @@ class Image : public ::Image {
264264 */
265265 void Load (const ::Texture2D& texture) {
266266 set (::LoadImageFromTexture (texture));
267- if (!IsReady ()) {
267+ if (!IsValid ()) {
268268 throw RaylibException (" Failed to load Image from texture." );
269269 }
270270 }
@@ -728,7 +728,7 @@ class Image : public ::Image {
728728 *
729729 * @return True or false depending on whether the Image has been loaded.
730730 */
731- bool IsReady () const { return ::IsImageReady (*this ); }
731+ bool IsValid () const { return ::IsImageValid (*this ); }
732732protected:
733733 void set (const ::Image& image) {
734734 data = image.data ;
0 commit comments