Skip to content

Commit 1985d98

Browse files
committed
backend.surfaceless: get rid of the render_fd hack for mpv, not required
That's only for hwdec anyway, who cares, encoding is going to be the bottleneck anyway.
1 parent 4abb8fa commit 1985d98

1 file changed

Lines changed: 2 additions & 11 deletions

File tree

blitzloop/backend/surfaceless.py

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -67,15 +67,6 @@ def __init__(self, width=640, height=480, fullscreen=False, aspect=None):
6767
num_configs = ctypes.c_long()
6868
egl.eglChooseConfig(self.disp, attribList, byref(config), 1, byref(num_configs))
6969

70-
# *Sigh* this works for now
71-
for i in os.listdir("/proc/self/fd"):
72-
try:
73-
target = os.readlink("/proc/self/fd/%s" % i)
74-
if target.startswith("/dev/dri/render"):
75-
self.render_fd = int(i)
76-
except:
77-
pass
78-
7970
ret = ctypes.c_int()
8071
egl.eglBindAPI(egl.EGL_OPENGL_ES_API)
8172

@@ -106,8 +97,8 @@ def get_proc_address(self, s):
10697

10798
def get_mpv_params(self):
10899
return { "drm_display": {
109-
"fd": self.render_fd,
110-
"render_fd": self.render_fd,
100+
"fd": -1,
101+
"render_fd": -1,
111102
} }
112103

113104
if __name__ == "__main__":

0 commit comments

Comments
 (0)