8000 feature request: binary wheels for 32 bit windows x86 with opengl 2.0 · Issue #167 · electronstudio/raylib-python-cffi · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

feature request: binary wheels for 32 bit windows x86 with opengl 2.0 #167

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
ABDS67 opened this issue Mar 24, 2025 · 31 comments
Open

feature request: binary wheels for 32 bit windows x86 with opengl 2.0 #167

ABDS67 opened this issue Mar 24, 2025 · 31 comments 8000
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@ABDS67
Copy link
ABDS67 commented Mar 24, 2025

Hi, I'am a fan of game development I am on windows 7 32 bit and I use VSCode I want to use raylib
I Installed Raylib 5.0.0.0 Successfully

But when I wrote this code in VSCode:

Image

It said:
Traceback (most recent call last):
File "c:\Users\samir\Desktop\My Games\Raylib\SpaceShooter\base.py", line 1, in
from pyray import *
File "C:\Users\samir\AppData\Local\Programs\Python\Python38-32\lib\site-packages\pyray_init_.py", line 15, in
from raylib import rl, ffi
File "C:\Users\samir\AppData\Local\Programs\Python\Python38-32\lib\site-packages\raylib_init_.py", line 15, in
from ._raylib_cffi import ffi, lib as rl
ModuleNotFoundError: No module named 'raylib._raylib_cffi'

@electronstudio
Copy link
Owner

#142

@electronstudio
Copy link
Owner

Also, why are you using 5.0.0.0 ? It’s buggy. Use latest 5.5.0.2 or if you really insist on 5.0 then use 5.0.0.5.

@electronstudio
Copy link
Owner
electronstudio commented Mar 24, 2025

So, assuming you’ve read #142 you have probably realised the cause is there is no binary wheel for 32 bit windows. So you have two options:

  1. Use the raylib_dynamic package instead of raylib package (may have to supply your own 32 bit Raylib DLL, not sure)
  2. Compile from source.

Btw, not related to this, but don’t import both pyray and raylib, it may cause confusion later.

@electronstudio
Copy link
Owner

If you go for raylib_dynamic option you’ll need to set environment variable USE_EXTERNAL_RAYLIB=1 and put a 32 bit raylib.dll file from https://github.com/raysan5/raylib/releases/download/5.5/raylib-5.5_win32_msvc16.zip in the current directory.

@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

hello sorry for not answering, can you tell me how to install https://github.com/raysan5/raylib/releases/download/5.5/raylib-5.5_win32_msvc16.zip I download it and I don't know how to use it

@electronstudio
Copy link
Owner

i made a video of what you need to do: https://github.com/user-attachments/assets/ef3b37ad-73e8-41af-bb0d-1d35814d4829

I get an error at the end because I'm on 64 bit windows but you wont get that.

@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

a window pop up

pythonw.exe - Image incorrect
it sed that (my path of python) raylib.dll designed to run under Windows or it contains an error. Install the program again using the original installation media.

in the console:
cannot load library 'C:\Users\samir\AppData\Local\Programs\Python\Python38-32\lib\site-packages\raylib\raylib.dll': error 0xc1
Traceback (most recent call last):
File "C:\Users\samir\Desktop\My Games\Raylib\SpaceShooter\base.py", line 1, in
from pyray import *
File "C:\Users\samir\AppData\Local\Programs\Python\Python38-32\lib\site-packages\pyray_init_.py", line 18, in
from raylib import rl, ffi
ImportError: cannot import name 'rl' from 'raylib' (C:\Users\samir\AppData\Local\Programs\Python\Python38-32\lib\site-packages\raylib_init_.py)

@electronstudio
Copy link
Owner

looks like you didnt SET USE_EXTERNAL_RAYLIB=1

@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

I did all the steps in your video

@electronstudio
Copy link
Owner

If USE_EXTERNAL_RAYLIB is set then it will try to load 'raylib.dll' from current directory. It isn't doing that, it's loading from 'C:\Users\samir\AppData\Local\Programs\Python\Python38-32\lib\site-packages\raylib\raylib.dll'. So I don't know what else to tell you.

8000
@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

thank you for help and sorry for annoyance

@electronstudio
Copy link
Owner

If you're not using cmd.exe as your shell then syntax to set a variable might be different. For example in bash it's 'export' not 'SET'.

@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

no I use it (cmd.exe)

@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

but I need to write SET in capital letters or lowcase letters

@electronstudio
Copy link
Owner

nasty hack solution:
COPY raylib.dll C:\Users\samir\AppData\Local\Programs\Python\Python38-32\lib\site-packages\raylib\

@electronstudio
Copy link
Owner

that should overwrite the 64 bit dll in the package with the 32 bit you downloaded

@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

where i put the coppied file

@electronstudio
Copy link
Owner

C:\Users\samir\AppData\Local\Programs\Python\Python38-32\lib\site-packages\raylib\raylib.dll

@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

we are going in the right way but:
the old problem has gone but:
a window pop up and sed:

python has stopped working

A problem caused the program to stop working correctly. Windows will close this program and tell you if a solution is available.

@electronstudio
Copy link
Owner

is it printing an error?

@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

in the console:
LOADED DYNAMICALLY SHARED LIB 5.5.0.2 C:\Users\samir\AppData\Local\Programs\Python\Python38-32\lib\site-packages\raylib\raylib.dll
sorry deprecated enums dont work on dynamic version

@electronstudio
Copy link
Owner

what else does it print? post everything

@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

the console one the one before it, that all

< 8000 div class="js-timeline-item js-timeline-progressive-focus-container" data-gid="IC_kwDOCzHBXM6km4pF">
@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

wait there is a warning

@electronstudio
Copy link
Owner

raylib usually prints something like

NFO: Initializing raylib 5.5
INFO: Platform backend: DESKTOP (GLFW)
INFO: Supported raylib modules:
INFO:     > rcore:..... loaded (mandatory)
INFO:     > rlgl:...... loaded (mandatory)
INFO:     > rshapes:... loaded (optional)
INFO:     > rtextures:. loaded (optional)
INFO:     > rtext:..... loaded (optional)
INFO:     > rmodels:... loaded (optional)
INFO:     > raudio:.... loaded (optional)
INFO: DISPLAY: Device initialized successfully
INFO:     > Display size: 1920 x 1200
INFO:     > Screen size:  300 x 300
INFO:     > Render size:  300 x 300
INFO:     > Viewport offsets: 0, 0
INFO: GLAD: OpenGL extensions loaded successfully
INFO: GL: Supported extensions count: 401
INFO: GL: OpenGL device information:
INFO:     > Vendor:   NVIDIA Corporation
INFO:     > Renderer: NVIDIA GeForce RTX 4070 Ti/PCIe/SSE2
INFO:     > Version:  3.3.0 NVIDIA 570.124.04
INFO:     > GLSL:     3.30 NVIDIA via Cg compiler
INFO: GL: VAO extension detected, VAO functions loaded successfully
INFO: GL: NPOT textures extension detected, full NPOT textures supported
INFO: GL: DXT compressed textures supported
INFO: GL: ETC2/EAC compressed textures supported

@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

yes and after it there is the warning i will write it

@electronstudio
Copy link
Owner

post everything it prints

@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

in the cmd:

WARNING: GLFW: Error: 65543 Description: WGL: OpenGL profile requested but WGL_A
RB_create_context_profile is unavailable

@electronstudio
Copy link
Owner

If it is printing the INFO lines, post them.

Mostly likely you don't have a GPU that supports opengl 3.3

@ABDS67
Copy link
Author
ABDS67 commented Mar 28, 2025

LOADED DYNAMICALLY SHARED LIB 5.5.0.2 C:\Users\samir\AppData\Local\Programs\Pyth
on\Python38-32\lib\site-packages\raylib\raylib.dll
sorry deprecated enums dont work on dynamic version
INFO: Initializing raylib 5.5
INFO: Platform backend: DESKTOP (GLFW)
INFO: Supported raylib modules:
INFO: > rcore:..... loaded (mandatory)
INFO: > rlgl:...... loaded (mandatory)
INFO: > rshapes:... loaded (optional)
INFO: > rtextures:. loaded (optional)
INFO: > rtext:..... loaded (optional)
INFO: > rmodels:... loaded (optional)
INFO: > raudio:.... loaded (optional)
WARNING: GLFW: Error: 65543 Description: WGL: OpenGL profile requested but WGL_A
RB_create_context_profile is unavailable

that all and you are right my GPU doesn't OpenGL 3.3

@electronstudio
Copy link
Owner

You need to find out what version of OpenGL your GPU supports and then re-compile Raylib for that version. You can get help on that on the Raylib Discord.

Also it might be better to install Linux on this machine, it tends to support old machines better than Windows does and compiling stuff is easier.

@electronstudio electronstudio changed the title No module named 'raylib._raylib_cffi' feature request: binary wheels for 32 bit windows x86 with opengl 2.0 Mar 29, 2025
@electronstudio electronstudio added enhancement New feature or request help wanted Extra attention is needed labels Mar 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants
0