Giter Site home page Giter Site logo

Comments (5)

ankith26 avatar ankith26 commented on June 15, 2024

Linking the Window issue because it's relevant: #2603

from pygame-ce.

ankith26 avatar ankith26 commented on June 15, 2024

Here is the gdb backtrace

#0  0x00007ffff2db3f60 in ??? ()
#1  0x00007ffff7725e83 in GL_DestroyTexture (renderer=<optimized out>, texture=0x203f5b0)
    at /usr/src/libsdl2-2.28.3+dfsg-2/src/render/opengl/SDL_render_gl.c:1509
#2  0x00007ffff772c00c in SDL_DestroyTexture_REAL (texture=0x203f5b0) at /usr/src/libsdl2-2.28.3+dfsg-2/src/render/SDL_render.c:4287
#3  0x00007ffff3474d6e in __pyx_pf_6pygame_5_sdl2_5video_7Texture_4__dealloc__ (__pyx_v_self=0x7ffff7a46400)
    at src_c/_sdl2/video.c:8117
#4  __pyx_pw_6pygame_5_sdl2_5video_7Texture_5__dealloc__ (__pyx_v_self=0x7ffff7a46400) at src_c/_sdl2/video.c:8089
#5  __pyx_tp_dealloc_6pygame_5_sdl2_5video_Texture (o=0x7ffff7a46400) at src_c/_sdl2/video.c:21316
#6  0x000000000055e361 in _Py_Dealloc (op=<optimized out>) at ../Objects/object.c:2390
#7  Py_DECREF (op=<optimized out>) at ../Include/object.h:538
#8  Py_XDECREF (op=<optimized out>) at ../Include/object.h:602
#9  free_keys_object (keys=0x12e2d70) at ../Objects/dictobject.c:664
#10 dictkeys_decref (dk=0x12e2d70) at ../Objects/dictobject.c:324
#11 PyDict_Clear (op=<optimized out>) at ../Objects/dictobject.c:2108
#12 0x00000000005f2dca in dict_tp_clear (op=<optimized out>) at ../Objects/dictobject.c:3566
#13 0x00000000004d30b0 in delete_garbage
    (old=0xa56988 <_PyRuntime+59656>, collectable=0x7fffffffd470, gcstate=0xa56940 <_PyRuntime+59584>, tstate=0xa70a38 <_PyRuntime+166328>) at ../Modules/gcmodule.c:1013
#14 gc_collect_main (tstate=0xa70a38 <_PyRuntime+166328>, generation=2, n_collected=0x0, n_uncollectable=0x0, nofail=1)
    at ../Modules/gcmodule.c:1287
#15 0x0000000000610230 in _PyGC_CollectNoFail.isra.0 (tstate=tstate@entry=0xa70a38 <_PyRuntime+166328>) at ../Modules/gcmodule.c:2110
#16 0x000000000060f831 in finalize_modules (tstate=0xa70a38 <_PyRuntime+166328>) at ../Python/pylifecycle.c:1560
#17 0x00000000005f6f88 in Py_FinalizeEx () at ../Python/pylifecycle.c:1833
#18 0x0000000000606745 in Py_RunMain () at ../Modules/main.c:682
#19 0x00000000005cb9db in Py_BytesMain (argc=<optimized out>, argv=<optimized out>) at ../Modules/main.c:734
#20 0x00007ffff7c280d0 in __libc_start_call_main (main=main@entry=0x5cb940 <main>, argc=argc@entry=2, argv=argv@entry=0x7fffffffd848)
    at ../sysdeps/nptl/libc_start_call_main.h:58
--Type <RET> for more, q to quit, c to continue without paging--
#21 0x00007ffff7c28189 in __libc_start_main_impl
    (main=0x5cb940 <main>, argc=2, argv=0x7fffffffd848, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7fffffffd838) at ../csu/libc-start.c:360
#22 0x00000000005cb875 in _start ()

So basically segfault happens in Texture dealloc

from pygame-ce.

Starbuck5 avatar Starbuck5 commented on June 15, 2024

Segfault happens in texture dealloc?

I'd like to confirm that this is not window related. It seems like if you had an app not using textures it should raise the pygame.error, operation not supported, and that would be fine.

from pygame-ce.

Starbuck5 avatar Starbuck5 commented on June 15, 2024

Also yeesh, opacity doesn't work on wayland, always_on_top doesn't work on wayland...

from pygame-ce.

ankith26 avatar ankith26 commented on June 15, 2024

Okay so I commented out all the Texture usages in that examples, and then Renderer dealloc started segfaulting.

However, simple software rendering with pygame.Window works just fine, thankfully

UPDATE: okay so I could get the video example to work under wayland, but had do to a couple of workarounds

  1. obviously, comment out the opacity set part
  2. and more importantly, manually del all Textures and Renderers used in the code before calling pygame.quit by doing
del renderer
del renderer2
del streamtex
del tex
del tex2

from pygame-ce.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.