"JPEG loading error" on Android

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Post Reply
Message
Author
User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 3791
Joined: Mon Dec 14, 2015 5:05 am
itch: Imperf3kt
Location: Your monitor
Contact:

"JPEG loading error" on Android

#1 Post by Imperf3kt »

I've come across a weird error I cannot get my head around.
My project was initially 9:16, for reasons, I made a 16:9 version as well.

When testing my game on a Windows PC, it runs fine.
Running the game via the Android emulator, also works fine.
When built as an .apk package and installed on an Android device that runs the 9:16 game just fine, I am met with the following error.

Code: Select all

I'm sorry, but an uncaught exception occurred.

While loading <'Image' u'images/zero.jpg'>:
  File "renpy/common/000window.rpy", line 98, in _window_auto_callback
  File "renpy/common/000window.rpy", line 60, in _window_show
Exception: Could not load image u'images/zero.jpg': error('JPEG loading error',)

-- Full Traceback ------------------------------------------------------------

Full traceback:
  File "script.rpyc", line 70, in script
  File "/data/user/0/com.arps/files/renpy/ast.py", line 644, in execute
    statement_name("say")
  File "/data/user/0/com.arps/files/renpy/ast.py", line 45, in statement_name
    i(name)
  File "renpy/common/000window.rpy", line 98, in _window_auto_callback
  File "renpy/common/000window.rpy", line 60, in _window_show
  File "/data/user/0/com.arps/files/renpy/exports.py", line 1456, in with_statement
    return renpy.game.interface.do_with(trans, paired, clear=clear)
  File "/data/user/0/com.arps/files/renpy/display/core.py", line 2217, in do_with
    clear=clear)
  File "/data/user/0/com.arps/files/renpy/display/core.py", line 2662, in interact
    repeat, rv = self.interact_core(preloads=preloads, trans_pause=trans_pause, **kwargs)
  File "/data/user/0/com.arps/files/renpy/display/core.py", line 3148, in interact_core
    self.draw_screen(root_widget, fullscreen_video, (not fullscreen_video) or video_frame_drawn)
  File "/data/user/0/com.arps/files/renpy/display/core.py", line 2065, in draw_screen
    renpy.config.screen_height,
  File "render.pyx", line 487, in renpy.display.render.render_screen
  File "render.pyx", line 235, in renpy.display.render.render
  File "/data/user/0/com.arps/files/renpy/display/layout.py", line 719, in render
    surf = render(child, width, height, cst, cat)
  File "render.pyx", line 147, in renpy.display.render.render
  File "render.pyx", line 235, in renpy.display.render.render
  File "/data/user/0/com.arps/files/renpy/display/transition.py", line 360, in render
    bottom = render(self.old_widget, width, height, st, at)
  File "render.pyx", line 147, in renpy.display.render.render
  File "render.pyx", line 235, in renpy.display.render.render
  File "/data/user/0/com.arps/files/renpy/display/layout.py", line 719, in render
    surf = render(child, width, height, cst, cat)
  File "render.pyx", line 147, in renpy.display.render.render
  File "render.pyx", line 235, in renpy.display.render.render
  File "/data/user/0/com.arps/files/renpy/display/layout.py", line 719, in render
    surf = render(child, width, height, cst, cat)
  File "render.pyx", line 147, in renpy.display.render.render
  File "render.pyx", line 235, in renpy.display.render.render
  File "accelerator.pyx", line 110, in renpy.display.accelerator.transform_render
  File "render.pyx", line 235, in renpy.display.render.render
  File "/data/user/0/com.arps/files/renpy/display/image.py", line 497, in render
    return wrap_render(self.target, width, height, st, at)
  File "/data/user/0/com.arps/files/renpy/display/image.py", line 306, in wrap_render
    rend = render(child, w, h, st, at)
  File "render.pyx", line 147, in renpy.display.render.render
  File "render.pyx", line 235, in renpy.display.render.render
  File "/data/user/0/com.arps/files/renpy/display/im.py", line 580, in render
    return cache.get(self, render=True)
  File "/data/user/0/com.arps/files/renpy/display/im.py", line 266, in get
    surf = image.load()
  File "/data/user/0/com.arps/files/renpy/display/im.py", line 625, in load
    surf = renpy.display.pgrender.load_image(renpy.loader.load(self.filename), self.filename)
  File "/data/user/0/com.arps/files/renpy/display/pgrender.py", line 162, in load_image
    raise Exception("Could not load image {!r}: {!r}".format(filename, e))
Exception: Could not load image u'images/zero.jpg': error('JPEG loading error',)

Anybody able to discern why this is happening? If I convert the images to .png, everything works fine.
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Current project: GGD Mentor

Twitter

Post Reply

Who is online

Users browsing this forum: Ocelot, Shie