projects/guix·blob crypto-team · refs

1256 lines · 49.2 KiB

1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2020, 2023 Lars-Dominik Braun <[email protected]>
3;;; Copyright © 2021 Adam Kandur <[email protected]>
4;;; Copyright © 2021 Ekaitz Zarraga <[email protected]>
5;;; Copyright © 2021 Ludovic Courtès <[email protected]>
6;;; Copyright © 2021 Morgan Smith <[email protected]>
7;;; Copyright © 2021, 2023 Daniel Meißner <[email protected]>
8;;; Copyright © 2022 Jean-Pierre De Jesus DIAZ <[email protected]>
9;;; Copyright © 2022 Marius Bakke <[email protected]>
10;;; Copyright © 2022 Ryan Prior <[email protected]>
11;;; Copyright © 2023 Adam Faiz <[email protected]>
12;;; Copyright © 2023 Simon Tournier <[email protected]>
13;;; Copyright © 2024 Artyom V. Poptsov <[email protected]>
14;;; Copyright © 2024-2025 Sharlatan Hellseher <[email protected]>
15;;; Copyright © 2025 Sisiutl <[email protected]>
16;;;
17;;; This file is part of GNU Guix.
18;;;
19;;; GNU Guix is free software; you can redistribute it and/or modify it
20;;; under the terms of the GNU General Public License as published by
21;;; the Free Software Foundation; either version 3 of the License, or (at
22;;; your option) any later version.
23;;;
24;;; GNU Guix is distributed in the hope that it will be useful, but
25;;; WITHOUT ANY WARRANTY; without even the implied warranty of
26;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
27;;; GNU General Public License for more details.
28;;;
29;;; You should have received a copy of the GNU General Public License
30;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
31
32(define-module (gnu packages python-graphics)
33 #:use-module ((guix licenses) #:prefix license:)
34 #:use-module (guix build-system pyproject)
35 #:use-module (guix download)
36 #:use-module (guix gexp)
37 #:use-module (guix git-download)
38 #:use-module (guix packages)
39 #:use-module (gnu packages)
40 #:use-module (gnu packages audio)
41 #:use-module (gnu packages base)
42 #:use-module (gnu packages boost)
43 #:use-module (gnu packages check)
44 #:use-module (gnu packages cmake)
45 #:use-module (gnu packages compression)
46 #:use-module (gnu packages fontutils)
47 #:use-module (gnu packages game-development)
48 #:use-module (gnu packages gl)
49 #:use-module (gnu packages graphics)
50 #:use-module (gnu packages gstreamer)
51 #:use-module (gnu packages gtk)
52 #:use-module (gnu packages image)
53 #:use-module (gnu packages maths)
54 #:use-module (gnu packages pkg-config)
55 #:use-module (gnu packages pulseaudio)
56 #:use-module (gnu packages python)
57 #:use-module (gnu packages python-build)
58 #:use-module (gnu packages python-check)
59 #:use-module (gnu packages python-science)
60 #:use-module (gnu packages python-web)
61 #:use-module (gnu packages python-xyz)
62 #:use-module (gnu packages qt)
63 #:use-module (gnu packages sdl)
64 #:use-module (gnu packages simulation)
65 #:use-module (gnu packages swig)
66 #:use-module (gnu packages tex)
67 #:use-module (gnu packages video)
68 #:use-module (gnu packages xorg))
69
70;;; Commentary:
71;;;
72;;; Python modules which are meant to be used in GUI creation or mainly are
73;;; bindings to low level libraries such as Glue, Mesa, OpenGL, Xorg etc.
74;;;
75;;; Please: Try to add new module packages in alphabetic order.
76;;;
77;;; Code:
78
79(define-public python-asyncgui
80 (package
81 (name "python-asyncgui")
82 (version "0.11.1")
83 (source
84 (origin
85 (method git-fetch)
86 (uri (git-reference
87 (url "https://github.com/asyncgui/asyncgui")
88 (commit (string-append "v" version))))
89 (file-name (git-file-name name version))
90 (sha256
91 (base32 "0fcd4gshygwcfpmxb3sas9awp15rv3m3m1gcxdbf2vrbdchdqhgf"))))
92 (build-system pyproject-build-system)
93 (arguments
94 (list
95 #:build-backend "poetry.core.masonry.api"))
96 (native-inputs
97 (list python-poetry-core
98 python-pytest))
99 (home-page "https://github.com/asyncgui/asyncgui")
100 (synopsis "Enables async/await without an event loop")
101 (description
102 "This package provides support for async/await applications without
103requiring an event loop, useful for creative responsive GUIs.")
104 (license license:expat)))
105
106(define-public python-asynckivy
107 (package
108 (name "python-asynckivy")
109 (version "0.11.0")
110 (source
111 (origin
112 (method git-fetch)
113 (uri (git-reference
114 (url "https://github.com/asyncgui/asynckivy")
115 (commit (string-append "v" version))))
116 (file-name (git-file-name name version))
117 (sha256
118 (base32 "0jxij58ax5lpnhhmhvvbf3sa1mdrbpq6kxab9r25lzgsbqjxj62z"))))
119 (build-system pyproject-build-system)
120 (arguments
121 (list
122 #:build-backend "poetry.core.masonry.api"
123 ;; XXX: Tests need some setup: AttributeError: 'NoneType' object has no
124 ;; attribute 'create_window'.
125 #:tests? #f))
126 (native-inputs
127 (list python-poetry-core))
128 (propagated-inputs
129 (list python-asyncgui))
130 (home-page "https://github.com/asyncgui/asynckivy")
131 (synopsis "Async library for Kivy")
132 (description
133 "This package provides async versions of Kivy functions to avoid the
134callback-heavy mode of interaction typical in some Kivy applications.")
135 (license license:expat)))
136
137(define-public python-glcontext
138 (let (;; Upstream is known for abusing mutable tag, hence pinpoint the
139 ;; relevant commit.
140 (revision "2")
141 (commit "f2875abdb18b24e785c3958cc22845c81725d5cd"))
142 (package
143 (name "python-glcontext")
144 (version (git-version "3.0.0" revision commit))
145 (source
146 (origin
147 (method git-fetch)
148 (uri (git-reference
149 (url "https://github.com/moderngl/glcontext")
150 (commit commit)))
151 (file-name (git-file-name name version))
152 (sha256
153 (base32 "15pngnc4agdvm8crq782vjlb5v1qrclln5xpqiyhz3jhmipsqb8q"))))
154 (build-system pyproject-build-system)
155 (arguments
156 (list
157 #:phases
158 #~(modify-phases %standard-phases
159 (add-before 'build 'fix-lib-paths
160 (lambda* (#:key inputs outputs #:allow-other-keys)
161 (let ((mesa (assoc-ref inputs "mesa"))
162 (libx11 (assoc-ref inputs "libx11")))
163 (substitute* '("glcontext/x11.cpp"
164 "glcontext/egl.cpp")
165 (("\"libGL.so\"")
166 (string-append "\"" mesa "/lib/libGL.so\""))
167 (("\"libEGL.so\"")
168 (string-append "\"" mesa "/lib/libEGL.so\""))
169 (("\"libX11.so\"")
170 (string-append "\"" libx11 "/lib/libX11.so\"")))
171 (substitute* '("glcontext/__init__.py")
172 (("find_library\\('GL'\\)")
173 (string-append "'" mesa "/lib/libGL.so'"))
174 (("find_library\\('EGL'\\)")
175 (string-append "'" mesa "/lib/libEGL.so'"))
176 (("find_library\\(\"X11\"\\)")
177 (string-append "'" libx11 "/lib/libX11.so'"))))))
178 (add-before 'check 'prepare-test-environment
179 (lambda _
180 (system "Xvfb :1 &")
181 (setenv "DISPLAY" ":1"))))))
182 (inputs
183 (list libx11
184 mesa))
185 (native-inputs
186 (list python-psutil
187 python-pytest
188 python-setuptools
189 python-wheel
190 xorg-server-for-tests))
191 (home-page "https://github.com/moderngl/glcontext")
192 (synopsis "Portable OpenGL Context for ModernGL")
193 (description
194 "Python-glcontext is a library providing an OpenGL implementation for
195ModernGL on multiple platforms.")
196 (license license:expat))))
197
198(define-public python-glfw
199 (package
200 (name "python-glfw")
201 (version "2.8.0")
202 (source
203 (origin
204 (method url-fetch)
205 (uri (pypi-uri "glfw" version))
206 (sha256
207 (base32 "1w36jvn6fx8p7irhwj6bbl67m2id3s0227b3w7bgw9hbicr0vsch"))))
208 (build-system pyproject-build-system)
209 (arguments
210 (list
211 #:tests? #f ; no tests provided
212 #:phases
213 #~(modify-phases %standard-phases
214 (add-after 'unpack 'fix-lib-paths
215 (lambda _
216 (substitute* "glfw/library.py"
217 (("_get_library_search_paths\\(\\), ")
218 (format #f "[ '~a/lib' ],"
219 #$(this-package-input "glfw")))))))))
220 (native-inputs
221 (list python-pytest
222 python-setuptools
223 python-wheel))
224 (inputs
225 (list glfw))
226 (home-page "https://github.com/FlorianRhiem/pyGLFW")
227 (synopsis "Python bindings for GLFW")
228 (description
229 "This package provides Python bindings for @url{http://www.glfw.org/,
230GLFW} OpenGL application development library.")
231 (license license:expat)))
232
233(define-public python-isosurfaces
234 (package
235 (name "python-isosurfaces")
236 (version "0.1.2")
237 (source
238 (origin
239 (method git-fetch)
240 (uri (git-reference
241 (url "https://github.com/jared-hughes/isosurfaces")
242 (commit (string-append "v" version))))
243 (file-name (git-file-name name version))
244 (sha256
245 (base32 "11rmbx6hfjz14sykcmqasg4akqm31b67v95sxaxcnkpmqqq8kqzz"))))
246 (build-system pyproject-build-system)
247 (arguments
248 (list
249 #:tests? #f)) ;no tests provided.
250 (native-inputs
251 (list python-setuptools))
252 (propagated-inputs
253 (list python-numpy))
254 (home-page "https://github.com/jared-hughes/isosurfaces")
255 (synopsis "Construct isolines/isosurfaces over a 2D/3D scalar field")
256 (description
257 "Construct isolines/isosurfaces of a 2D/3D scalar field defined by a
258function, i.e. curves over which @code{f(x,y)=0} or surfaces over which
259@code{f(x,y,z)=0}. Most similar libraries use marching squares or similar
260over a uniform grid, but this uses a quadtree to avoid wasting time sampling
261many far from the implicit surface.")
262 (license license:expat)))
263
264(define-public python-kivy
265 (package
266 (name "python-kivy")
267 ;; 2.3.1 (2024-12-26), to suport Python 3.12+ and Cython 3+.
268 (properties '((commit . "92d2cc2f56453c55ae7913e1a64809df6cc61ae5")
269 (revision . "1")))
270 (version (git-version "2.3.1"
271 (assoc-ref properties 'revision)
272 (assoc-ref properties 'commit)))
273 (source
274 (origin
275 (method git-fetch)
276 (uri (git-reference
277 (url "https://github.com/kivy/kivy")
278 (commit (assoc-ref properties 'commit))))
279 (file-name (git-file-name name version))
280 (sha256
281 (base32 "19fk1l061kjmnhm2yl4vym323s53x1p4jfb1armfd4ly5h0ik0m0"))))
282 (build-system pyproject-build-system)
283 (arguments
284 `(#:tests? #f ; Tests require many optional packages
285 #:phases
286 (modify-phases %standard-phases
287 (add-after 'patch-generated-file-shebangs 'set-sdl-paths
288 (lambda* (#:key inputs #:allow-other-keys)
289 (setenv "KIVY_SDL2_PATH"
290 (search-input-directory inputs "/include/SDL2"))))
291 (add-before 'build 'set-home
292 (lambda _
293 ;; 'kivy/__init__.py' wants to create $HOME/.kivy.
294 (setenv "HOME" (getcwd)))))))
295 (native-inputs
296 (list pkg-config
297 python-cython
298 ;; Not packaged yet, for tests.
299 ;; python-kivy-deps-glew
300 ;; python-kivy-deps-glew-dev
301 ;; python-kivy-deps-gstreamer
302 ;; python-kivy-deps-gstreamer-dev
303 ;; python-kivy-deps-sdl2
304 ;; python-kivy-deps-sdl2-dev
305 python-packaging
306 python-setuptools))
307 (inputs
308 (list gstreamer
309 mesa
310 (sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf))))
311 (propagated-inputs
312 (list python-docutils
313 python-filetype
314 python-kivy-garden
315 python-pygments
316 python-requests))
317 (home-page "https://kivy.org")
318 (synopsis "Multitouch application framework")
319 (description
320 "Kivy is a software library for rapid development of hardware-accelerated
321multitouch applications.")
322 (license license:expat)))
323
324(define-public python-kivymd
325 (package
326 (name "python-kivymd")
327 (version "1.1.1")
328 (source
329 (origin
330 (method git-fetch) ; no tests in PyPI release
331 (uri (git-reference
332 (url "https://github.com/kivymd/KivyMD")
333 (commit version)))
334 (file-name (git-file-name name version))
335 (sha256
336 (base32 "1nprldcm54qybbwf7zlb32fkmz375j8i3k3g41d6ykc6vasq3w5j"))))
337 (build-system pyproject-build-system)
338 (arguments
339 (list
340 #:test-flags
341 ;; <https://github.com/pyinstaller/pyinstaller> is not packaged yet in
342 ;; Guix.
343 #~(list "--ignore=kivymd/tests/pyinstaller"
344 "-k" (string-join
345 ;; FIXME: Only some tests passed, the most fail with err:
346 ;; ValueError: KivyMD: App object must be initialized
347 ;; before loading root widget.
348 (list "not test_backdrop_raw_app"
349 "test_bottom_navigation_m3_style_raw_app"
350 "test_card_m3_style_raw_app"
351 "test_chip_raw_app"
352 "test_imagelist_raw_app"
353 "test_list_raw_app"
354 "test_navigationdrawer_raw_app"
355 "test_tab_raw_app"
356 "test_textfield_raw_app")
357 " and not "))
358 #:phases
359 #~(modify-phases %standard-phases
360 (add-after 'unpack 'fix-modules
361 (lambda _
362 (substitute* "setup.py"
363 ;; If excluded, sanity check fails with error:
364 ;; ModuleNotFoundError: No module named 'kivymd.tools.release'
365 (("\"kivymd.tools.release\"") ""))
366 ;; Check phase fails struggling to find tests module.
367 (with-output-to-file "kivymd/tests/__init__.py"
368 (lambda _ (display "")))))
369 (add-before 'build 'set-home
370 (lambda _
371 ;; FileNotFoundError: [Errno 2] No such file or directory:
372 ;; '/homeless-shelter/.kivy'
373 (setenv "HOME" "/tmp"))))))
374 (native-inputs
375 (list python-docutils
376 python-pytest
377 python-pytest-asyncio
378 python-setuptools
379 python-wheel))
380 (propagated-inputs
381 (list python-kivy
382 python-pillow
383 python-pygments
384 python-kivy-garden))
385 (home-page "https://github.com/kivymd/KivyMD")
386 (synopsis "Material Design compliant widgets for use with Kivy")
387 (description
388 "This package provides Kivy widgets that approximate Google's Material
389Design spec without sacrificing ease of use or application performance.")
390 (license license:expat)))
391
392;; XXX: The package was placed here to prevent adding (gnu packages video) to
393;; (gnu packages maths) module, it fits more there.
394(define-public python-manim
395 (package
396 (name "python-manim")
397 (version "0.20.1")
398 (source
399 (origin
400 (method git-fetch)
401 (uri (git-reference
402 (url "https://github.com/ManimCommunity/manim")
403 (commit (string-append "v" version))))
404 (file-name (git-file-name name version))
405 (sha256
406 (base32 "1ifgcsz9dhb7qyqsi60q840wqcqfmqxf19r8qlncakziyqlfmwxd"))))
407 (build-system pyproject-build-system)
408 (arguments
409 (list
410 #:test-flags
411 #~(list "--numprocesses" (number->string (parallel-job-count))
412 ;; OpenGL tests skipped: require GPU/EGL acceleration
413 ;; unavailable in build environment. These tests pass on systems
414 ;; with proper GPU drivers.
415 ;;
416 ;; command/logging tests skipped: expected failures due to Guix
417 ;; build environment specifics (PATH wrapping, offline mode).
418 "-k" "not (opengl or OpenGL)"
419 "--ignore=tests/interface/test_commands.py"
420 "--ignore=tests/test_logging/test_logging.py")
421 #:phases
422 #~(modify-phases %standard-phases
423 (add-before 'check 'set-x-server
424 (lambda _
425 (system "Xvfb :1 -screen 0 1024x768x24 &")
426 (setenv "DISPLAY" ":1")))
427 (add-after 'unpack 'fix-pytest-config
428 (lambda _
429 (substitute* "pyproject.toml"
430 ((" -n auto ") " ")))))))
431 (native-inputs
432 (list python-hatchling
433 python-pytest
434 python-pytest-xdist
435 (texlive-local-tree
436 (list texlive-dvisvgm
437 texlive-fontspec
438 texlive-preview
439 texlive-standalone
440 texlive-xcolor))
441 xorg-server))
442 (propagated-inputs
443 (list ffmpeg
444 python-av
445 python-beautifulsoup4
446 python-click
447 python-cloup
448 python-decorator
449 python-isosurfaces
450 python-manimpango
451 python-mapbox-earcut
452 python-moderngl
453 python-moderngl-window
454 python-networkx
455 python-numpy
456 python-pillow
457 python-pycairo
458 python-pydub
459 python-pygments
460 python-rich
461 python-screeninfo
462 python-skia-pathops
463 python-srt
464 python-svgelements
465 python-tqdm
466 python-typing-extensions
467 python-watchdog))
468 (home-page "https://www.manim.community/")
469 (synopsis "Python animation engine for explanatory math videos")
470 (description
471 "Manim is a Python library for creating mathematical animations. The
472animations are written as Python code which is based on predefined objects.
473You can make animations with maths formulas (LaTeX-based), simple shapes, 3D
474objects, function graphs and more.")
475 (license license:expat)))
476
477(define-public python-mapbox-earcut
478 (package
479 (name "python-mapbox-earcut")
480 (version "2.0.0")
481 (source
482 (origin
483 (method git-fetch)
484 (uri (git-reference
485 (url "https://github.com/skogler/mapbox_earcut_python")
486 (commit (string-append "v" version))))
487 (file-name (git-file-name name version))
488 (sha256
489 (base32 "18mpr453wbfdaa95xsvhqy5vmb311ja59dzi0aizwdf3nwjh75j7"))))
490 (build-system pyproject-build-system)
491 (native-inputs
492 (list python-nanobind
493 python-pytest
494 python-scikit-build-core))
495 (propagated-inputs
496 (list python-numpy))
497 (home-page "https://github.com/skogler/mapbox_earcut_python")
498 (synopsis "Python bindings to the mapbox earcut C++ library")
499 (description
500 "Python bindings for the C++ implementation of the Mapbox Earcut library,
501which provides very fast and quite robust triangulation of 2D polygons.
502
503The library implements a modified ear slicing algorithm, optimized by z-order
504curve hashing and extended to handle holes, twisted polygons, degeneracies and
505self-intersections in a way that doesn't guarantee correctness of
506triangulation, but attempts to always produce acceptable results for practical
507data like geographical shapes.")
508 (license license:isc)))
509
510(define-public python-moderngl
511 (package
512 (name "python-moderngl")
513 (version "5.12.0")
514 (source
515 (origin
516 (method git-fetch)
517 (uri (git-reference
518 (url "https://github.com/moderngl/moderngl")
519 (commit version)))
520 (file-name (git-file-name name version))
521 (sha256
522 (base32 "0gf8cam9m6sz73ndlwz8a5vd0qz06lbww3lgfjcdmla6bwyxjxd5"))))
523 (build-system pyproject-build-system)
524 (arguments
525 (list
526 #:test-flags
527 #~(list "-k" "not (test_local or test_compute_shader)")))
528 (native-inputs
529 (list python-numpy
530 python-pyopengl
531 python-pytest
532 python-scipy-minimal
533 python-setuptools))
534 (propagated-inputs
535 (list python-glcontext))
536 (home-page "https://github.com/moderngl/moderngl")
537 (synopsis "Modern OpenGL binding for Python")
538 (description
539 "ModernGL is a Python wrapper over OpenGL Core. ModernGL simplifies the
540creation of graphics applications like scientific simulations, games or user
541interfaces. Usually, acquiring in-depth knowledge of OpenGL requires a steep
542learning curve. In contrast, ModernGL is easy to learn and use. ModernGL is
543capable of rendering with high performance and quality, with less code
544written.")
545 (license license:expat)))
546
547(define-public python-moderngl-window
548 (package
549 (name "python-moderngl-window")
550 (version "3.1.1")
551 (source
552 (origin
553 (method git-fetch)
554 (uri (git-reference
555 (url "https://github.com/moderngl/moderngl-window")
556 (commit version)))
557 (file-name (git-file-name name version))
558 (sha256
559 (base32 "1f5mnm1c92ssn7hww40k5yyz4r6b1d5xb2i9y99mcrjv6g1m4jd4"))))
560 (build-system pyproject-build-system)
561 (arguments
562 (list
563 #:phases
564 #~(modify-phases %standard-phases
565 (add-before 'check 'set-x-server
566 (lambda _
567 (system "Xvfb :1 &")
568 (setenv "DISPLAY" ":1"))))))
569 (native-inputs
570 (list python-pytest
571 python-pywavefront
572 python-setuptools
573 python-trimesh
574 xorg-server-for-tests))
575 (propagated-inputs
576 (list python-moderngl
577 python-numpy
578 python-pillow
579 python-pyglet
580 python-pyglm))
581 (home-page "https://github.com/moderngl/moderngl_window")
582 (synopsis "Helper library for ModernGL making window simple")
583 (description
584 "Cross platform utility library for ModernGL making window creation and
585resource loading simple. It can also be used with PyOpenGL for rendering with
586the programmable pipeline.
587
588Features:
589
590@itemize
591@item Cross platform support.
592@item Easily create a window for ModernGL using pyglet, pygame, PySide2, GLFW,
593SDL2, PyQt5 or tkinter supporting a wide range of window, keyboard and mouse
594events. These events are unified into a single system so your project can
595work with any window.
596@item Load 2D textures, texture arrays and cube maps using Pillow.
597@item Load shaders as single or multiple @code{glsl} files.
598@item Load objects/scenes from wavefront/obj, GLTF 2.0 or STL.
599@item Resource finder system supporting multiple resource directories.
600@item A highly plugable library supporting custom loaders, resource finders
601and windows.
602@item Type hints everywhere making code completion and linting a breeze.
603@end itemize")
604 (license license:expat)))
605
606(define-public python-pivy
607 (package
608 (name "python-pivy")
609 (version "0.6.11")
610 (source
611 (origin
612 (method git-fetch)
613 (uri (git-reference
614 (url "https://github.com/coin3d/pivy")
615 (commit version)))
616 (file-name (git-file-name name version))
617 (sha256
618 (base32 "0rjbhhxyrh0fszc0va7qmkv6ayf2s49ppnw31p51xmq63bx3n5wc"))))
619 (build-system pyproject-build-system)
620 (arguments
621 (list
622 ;; The test suite fails due to an import cycle between 'pivy' and '_coin'
623 #:tests? #f
624 #:phases
625 #~(modify-phases %standard-phases
626 (add-after 'unpack 'patch-cmake-include-dirs
627 (lambda _
628 ;; Patch buildsystem to respect Coin3D include directory
629 (substitute* "CMakeLists.txt"
630 (("\\$\\{SoQt_INCLUDE_DIRS}")
631 "${Coin_INCLUDE_DIR};${SoQt_INCLUDE_DIRS}")))))))
632 (native-inputs
633 (list cmake-minimal
634 python-setuptools
635 swig-4.4))
636 (inputs
637 (list qtbase
638 libxi
639 libice
640 glew
641 coin3d))
642 (home-page "https://github.com/coin3d/pivy")
643 (synopsis "Python bindings to Coin3D")
644 (description
645 "Pivy provides python bindings for Coin, a 3D graphics library with an
646Application Programming Interface based on the Open Inventor 2.1 API.")
647 (license license:isc)))
648
649(define-public python-py3exiv2
650 (package
651 (name "python-py3exiv2")
652 (version "0.12.0")
653 (source
654 (origin
655 (method url-fetch)
656 ;; Source: https://code.launchpad.net/py3exiv2
657 (uri (pypi-uri "py3exiv2" version))
658 (sha256
659 (base32 "12is7xb393wvq3la9lhi0y1xkmpvjj6v13cikb7k6iqcfrgkxckj"))))
660 (build-system pyproject-build-system)
661 (arguments
662 (list #:tests? #f)) ;no tests in PyPI
663 (native-inputs
664 (list boost
665 python-setuptools))
666 (inputs
667 (list exiv2))
668 (home-page "https://www.py3exiv2.tuxfamily.org/")
669 (synopsis "Python binding to the exiv2 library")
670 (description
671 "This package provides a Python binding to the library
672@code{https://exiv2.org/, exiv2} - cross-platform C++ library and a command
673line utility to manage image metadata.")
674 (license license:gpl3+)))
675
676(define-public python-pyglet
677 (package
678 (name "python-pyglet")
679 (version "2.0.18")
680 (source
681 (origin
682 (method url-fetch)
683 (uri (pypi-uri "pyglet" version))
684 (sha256
685 (base32 "1p4rizj81vfqxal288m3afbrgk0il3w7k5kmhai2sah8f26j7ybw"))))
686 (build-system pyproject-build-system)
687 (arguments
688 (list
689 #:test-flags
690 #~(list "tests"
691 "--ignore=tests/interactive"
692 ;; All tests errored
693 "--ignore=tests/integration/media/test_openal.py"
694 "--ignore=tests/integration/text/test_empty_document.py"
695 ;; Tests failed
696 "-k" (string-append "not test2"
697 " and not test5"
698 " and not testPad"
699 " and not testPad"
700 " and not testRange"
701 " and not testRect"
702 " and not testRect"
703 " and not testSet"
704 " and not testSquare"
705 " and not testSquare"
706 " and not testTuple"
707 " and not testTupleRange"
708 " and not test_context_noshare_texture"
709 " and not test_context_share_texture"
710 " and not test_method"
711 " and not test_openal_listener"
712 " and not test_parse_all_controller_mappings"
713 " and not test_player_play"
714 " and not test_player_play_multiple"
715 " and not test_stream_write_needed"
716 " and not test_window_caption"
717 " and not test_window_caption_from_argv"))
718 #:phases
719 #~(modify-phases %standard-phases
720 (add-after 'unpack 'patch-lib-paths
721 (lambda* (#:key inputs #:allow-other-keys)
722 (substitute* (list "pyglet/font/fontconfig.py"
723 "pyglet/font/freetype_lib.py"
724 "pyglet/gl/lib_glx.py"
725 "pyglet/input/linux/evdev.py"
726 "pyglet/libs/egl/egl.py"
727 "pyglet/libs/egl/lib.py"
728 "pyglet/libs/x11/xf86vmode.py"
729 "pyglet/libs/x11/xinerama.py"
730 "pyglet/libs/x11/xlib.py"
731 "pyglet/libs/x11/xsync.py"
732 "pyglet/media/drivers/openal/lib_openal.py"
733 "pyglet/media/drivers/pulse/lib_pulseaudio.py")
734 (("'EGL'")
735 (format #f "'~a/~a'" #$(this-package-input "mesa")
736 "lib/libEGL.so"))
737 (("\"fontconfig\"")
738 (format #f "'~a/~a'" #$(this-package-input "fontconfig-minimal")
739 "lib/libfontconfig.so"))
740 (("\"freetype\"")
741 (format #f "'~a/~a'" #$(this-package-input "freetype")
742 "lib/libfreetype.so"))
743 (("'GL'")
744 (format #f "'~a/~a'" #$(this-package-input "mesa")
745 "lib/libGL.so"))
746 (("'GLU'")
747 (format #f "'~a/~a'" #$(this-package-input "glu")
748 "lib/libGLU.so"))
749 (("'X11'")
750 (format #f "'~a/~a'" #$(this-package-input "libx11")
751 "lib/libX11.so"))
752 (("'Xext'")
753 (format #f "'~a/~a'" #$(this-package-input "libxext")
754 "lib/libXext.so"))
755 (("'Xinerama'")
756 (format #f "'~a/~a'" #$(this-package-input "libxinerama")
757 "lib/libXinerama.so"))
758 (("'Xxf86vm'")
759 (format #f "'~a/~a'" #$(this-package-input "libxxf86vm")
760 "lib/libXxf86vm.so"))
761 (("'c'")
762 (format #f "'~a/~a'" #$(this-package-input "glibc")
763 "lib/libc.so"))
764 (("'gdk-x11-2.0'")
765 (format #f "'~a/~a'" #$(this-package-input "gtk+")
766 "lib/gdk-pixbuf-2.0.so"))
767 (("'gdk_pixbuf-2.0'")
768 (format #f "'~a/~a'" #$(this-package-input "gdk-pixbuf")
769 "lib/libgdk_pixbuf-2.0.so"))
770 (("'openal'")
771 (format #f "'~a/~a'" #$(this-package-input "openal")
772 "lib/libopenal.so"))
773 (("'pulse'")
774 (format #f "'~a/~a'" #$(this-package-input "pulseaudio")
775 "lib/libpulse.so")))))
776 (add-before 'check 'prepare-test-environment
777 (lambda _
778 ;; The test suite requires a running X server.
779 (system "Xvfb :1 &")
780 (setenv "DISPLAY" ":1")
781 (setenv "HOME" "/tmp")
782 (setenv "PYGLET_HEADLESS" "True"))))))
783 (native-inputs
784 (list python-flit-core
785 python-pytest
786 unzip
787 xorg-server-for-tests))
788 (inputs
789 (list ffmpeg
790 fontconfig
791 freeglut
792 freetype
793 gdk-pixbuf
794 glibc
795 glu
796 gtk+
797 libx11
798 libxext
799 libxinerama
800 libxxf86vm
801 mesa
802 openal
803 pulseaudio))
804 (home-page "https://github.com/pyglet/pyglet")
805 (synopsis "Windowing and multimedia library")
806 (description
807 "Pyglet is a Python library for developing games and other visually-rich
808applications. It supports windowing, user interface event handling,
809Joysticks, OpenGL graphics, loading images and videos, playing sounds and
810music." )
811 (license license:bsd-3)))
812
813(define-public python-pyglet-1
814 (package
815 (inherit python-pyglet)
816 (name "python-pyglet")
817 (version "1.5.30") ;the latest 1.* version from 2024-12-24
818 (source
819 (origin
820 (method git-fetch)
821 (uri (git-reference
822 (url "https://github.com/pyglet/pyglet")
823 (commit (string-append "v" version))))
824 (file-name (git-file-name name version))
825 (sha256
826 (base32 "0q1690pqkks3na6vc8ps44h0gymlmq752xlk7fm0yvz05yqdqn51"))))
827 (arguments
828 (list
829 ;; tests: 317 passed, 24 skipped, 1 deselected, 2 warnings
830 #:test-flags
831 #~(list "--ignore=tests/base"
832 "--ignore=tests/interactive"
833 "--ignore=tests/integration/media"
834 "--ignore=tests/integration/font"
835 "--ignore=tests/integration/platform/test_linux_fontconfig.py"
836 ;; AssertionError: False is not true : Did not receive next
837 ;; expected event
838 "--ignore=tests/integration/window/test_event_sequence.py"
839 ;; pyglet.media.drivers.openal.interface.OpenALException: OpenAL
840 ;; Exception [40964: b'Invalid Value']: Failed to open device.
841 "--deselect=tests/unit/media/test_listener.py::test_openal_listener")
842 #:phases
843 #~(modify-phases %standard-phases
844 (add-after 'unpack 'fix-python-3.12-incompatibility
845 ;; The only user of pyglet@1 is printrun, see:
846 ;; <https://github.com/kliment/Printrun/issues/1468>.
847 (lambda _
848 (substitute* "tests/integration/test_toplevel_imports.py"
849 (("import imp") ""))))
850 (add-after 'unpack 'patch-lib-paths
851 (lambda* (#:key inputs #:allow-other-keys)
852 (substitute* (list "pyglet/font/fontconfig.py"
853 "pyglet/font/freetype_lib.py"
854 "pyglet/gl/lib_glx.py"
855 "pyglet/libs/egl/egl.py"
856 "pyglet/libs/egl/lib.py"
857 "pyglet/libs/x11/xf86vmode.py"
858 "pyglet/libs/x11/xinerama.py"
859 "pyglet/libs/x11/xlib.py"
860 "pyglet/libs/x11/xsync.py"
861 "pyglet/media/drivers/openal/lib_openal.py"
862 "pyglet/media/drivers/pulse/lib_pulseaudio.py")
863 (("'EGL'")
864 (format #f "'~a/~a'" #$(this-package-input "mesa")
865 "lib/libEGL.so"))
866 (("'fontconfig'")
867 (format #f "'~a/~a'" #$(this-package-input "fontconfig-minimal")
868 "lib/libfontconfig.so"))
869 (("'freetype'")
870 (format #f "'~a/~a'" #$(this-package-input "freetype")
871 "lib/libfreetype.so"))
872 (("'GL'")
873 (format #f "'~a/~a'" #$(this-package-input "mesa")
874 "lib/libGL.so"))
875 (("'GLU'")
876 (format #f "'~a/~a'" #$(this-package-input "glu")
877 "lib/libGLU.so"))
878 (("'X11'")
879 (format #f "'~a/~a'" #$(this-package-input "libx11")
880 "lib/libX11.so"))
881 (("'Xext'")
882 (format #f "'~a/~a'" #$(this-package-input "libxext")
883 "lib/libXext.so"))
884 (("'Xinerama'")
885 (format #f "'~a/~a'" #$(this-package-input "libxinerama")
886 "lib/libXinerama.so"))
887 (("'Xxf86vm'")
888 (format #f "'~a/~a'" #$(this-package-input "libxxf86vm")
889 "lib/libXxf86vm.so"))
890 (("'c'")
891 (format #f "'~a/~a'" #$(this-package-input "glibc")
892 "lib/libc.so"))
893 (("'gdk-x11-2.0'")
894 (format #f "'~a/~a'" #$(this-package-input "gtk+")
895 "lib/gdk-pixbuf-2.0.so"))
896 (("'gdk_pixbuf-2.0'")
897 (format #f "'~a/~a'" #$(this-package-input "gdk-pixbuf")
898 "lib/libgdk_pixbuf-2.0.so"))
899 (("'openal'")
900 (format #f "'~a/~a'" #$(this-package-input "openal")
901 "lib/libopenal.so"))
902 (("'pulse'")
903 (format #f "'~a/~a'" #$(this-package-input "pulseaudio")
904 "lib/libpulse.so")))))
905 (add-before 'check 'prepare-test-environment
906 (lambda _
907 ;; The test suite requires a running X server.
908 (system "Xvfb :1 &")
909 (setenv "DISPLAY" ":1")
910 (setenv "HOME" "/tmp")
911 (setenv "PYGLET_HEADLESS" "True"))))))
912 (native-inputs
913 (list python-pytest
914 python-setuptools
915 xorg-server-for-tests))))
916
917(define-public python-pyopengl
918 (package
919 (name "python-pyopengl")
920 (version "3.1.10")
921 (source
922 (origin
923 (method git-fetch)
924 (uri (git-reference
925 (url "https://github.com/mcfletch/pyopengl")
926 (commit version)))
927 (file-name (git-file-name name version))
928 (sha256
929 (base32 "0gn6n6z76xrvwj9inl2v6rr707n1w8s072qxfmzpla1i9bfckzjk"))))
930 (build-system pyproject-build-system)
931 (arguments
932 (list
933 ;; 62 passed, 26 skipped, 26 deselected, 2 xfailed, 2 warnings
934 #:test-flags
935 #~(list #$@(map (lambda (test) (string-append "--deselect=tests/" test))
936 (list
937 ;; RuntimeError: Test script failure on <...>
938 "test_checks.py::test_check_crash_on_glutinit"
939 "test_checks.py::test_check_egl_es1"
940 "test_checks.py::test_check_egl_es2"
941 "test_checks.py::test_check_egl_opengl"
942 "test_checks.py::test_check_glutwindow"
943 "test_checks.py::test_check_freeglut_deinit"
944 "test_checks.py::test_check_glut_debug"
945 "test_checks.py::test_check_glut_fc"
946 "test_checks.py::test_check_glut_load"
947 "test_checks.py::test_check_glutinit"
948 "test_checks.py::test_check_glutinit_0args"
949 "test_checks.py::test_check_glutinit_single"
950 "test_checks.py::test_check_glutinit_simplest"
951 "test_checks.py::test_egl_ext_enumerate"
952 "test_checks.py::test_test_instanced_draw_detect"
953 "test_checks.py::test_test_gldouble_ctypes"
954 ;; OpenGL.error.Error: Attempt to retrieve context when
955 ;; no valid context
956 "test_arraydatatype.py::TestCoreDatatype::test_numpyConversion"
957 "test_arraydatatype.py::TestCoreDatatype::test_pointers"
958 "test_core.py::TestCore::test_glCallLists_twice2"
959 "test_core.py::TestCore::test_glmultidraw"
960 ;; RuntimeError: Test Failed
961 "test_checks.py::test_feedbackvarying"
962 "test_checks.py::test_test_sf2946226"
963 "test_checks.py::test_test_glgetactiveuniform"
964 ;; TypeError: '<' not supported between instances of
965 ;; 'bool' and 'list'
966 "test_core.py::TestCore::test_get_read_fb_binding"
967 "test_core.py::TestCore::test_lookupint"
968 ;; assert not glShaderSource
969 "test_core.py::TestCore::test_get_version")))
970 #:phases
971 #~(modify-phases %standard-phases
972 (add-before 'build 'fix-paths
973 (lambda* (#:key inputs #:allow-other-keys)
974 (substitute* '("OpenGL/platform/ctypesloader.py")
975 (("filenames_to_try = \\[base_name\\]")
976 "filenames_to_try = [name]"))
977 (substitute* '("OpenGL/platform/glx.py"
978 "OpenGL/platform/egl.py"
979 "OpenGL/platform/osmesa.py"
980 "OpenGL/platform/darwin.py"
981 "tests/check_glut_load.py")
982 (("\"GLU\",")
983 (format #f "~s," (search-input-file inputs "lib/libGLU.so")))
984 (("'GLU',")
985 (format #f "~s," (search-input-file inputs "lib/libGLU.so")))
986 (("\"glut\",")
987 (format #f "~s," (search-input-file inputs "lib/libglut.so")))
988 (("'glut',")
989 (format #f "~s," (search-input-file inputs "lib/libglut.so")))
990 (("'(GL|EGL|GLESv1_CM|GLESv2)'" all gl-library)
991 (format #f "~s" (search-input-file inputs (string-append
992 "lib/lib"
993 gl-library ".so"))))
994 (("\"(GLESv1_CM|GLESv2)\"" all gl-library)
995 (format #f "~s" (search-input-file inputs (string-append
996 "lib/lib"
997 gl-library ".so")))))))
998 (add-before 'check 'pre-check
999 (lambda _
1000 (setenv "LANG" "fr_FR.UTF-8")
1001 (setenv "LANGUAGE" "fr_FR.UTF-8")
1002 (setenv "DISPLAY" ":1")
1003 (setenv "HOME" "/tmp")
1004 (setenv "USER" "guix")
1005 (setenv "XDG_RUNTIME_DIR" "/tmp")
1006 (setenv "XDG_SESSION_ID" "11235813")
1007 (setenv "XDG_SESSION_PATH" "/tmp")
1008 (setenv "XDG_SESSION_TYPE" "x11"))))))
1009 (native-inputs
1010 (list python-cython
1011 python-numpy
1012 python-psutil
1013 python-pygame-ce
1014 python-pytest
1015 python-setuptools))
1016 (inputs
1017 (list freeglut
1018 glu
1019 mesa))
1020 (home-page "https://pyopengl.sourceforge.net")
1021 (synopsis "Standard OpenGL bindings for Python")
1022 (description
1023 "PyOpenGL is the most common cross platform Python binding to OpenGL and
1024related APIs. The binding is created using the standard @code{ctypes}
1025library.")
1026 (license license:bsd-3)))
1027
1028(define-public python-pyopengl-accelerate
1029 (package
1030 (inherit python-pyopengl)
1031 (name "python-pyopengl-accelerate")
1032 (version "3.1.10")
1033 (source
1034 (origin
1035 (method url-fetch)
1036 (uri (pypi-uri "pyopengl_accelerate" version))
1037 (sha256
1038 (base32
1039 "0waskwvw9mp830bnnxcqd8bkh7a4qbnr0fcjnnw35xx6y21iqxc2"))))
1040 (arguments
1041 `(#:tests? #f
1042 #:phases
1043 (modify-phases %standard-phases
1044 (delete 'fix-paths))))
1045 (synopsis "Acceleration code for PyOpenGL")
1046 (description
1047 "This is the Cython-coded accelerator module for PyOpenGL.")))
1048
1049(define-public python-pysdl2
1050 (package
1051 (name "python-pysdl2")
1052 (version "0.9.17")
1053 (source
1054 (origin
1055 (method url-fetch)
1056 (uri (pypi-uri "pysdl2" version))
1057 (sha256
1058 (base32 "0axm6m3wj8x643zg65g60xdpaxanaqdilvp4yysks4pblh0yzij8"))))
1059 (build-system pyproject-build-system)
1060 (arguments
1061 (list
1062 #:tests? #f ;; Requires /dev/dri, OpenGL module, etc.
1063 #:phases
1064 #~(modify-phases %standard-phases
1065 (add-after 'unpack 'patch-paths
1066 (lambda _
1067 (substitute* "sdl2/dll.py"
1068 ;; Disable pysdl2-dll. It can't be packaged on GNU Guix
1069 ;; as it duplicates an existing package (sdl2).
1070 (("prepath = os\\.getenv\\('PYSDL2_DLL_PATH'\\)")
1071 "prepath = \"system\"")
1072 (("^import sdl2dll$") "")
1073 (("postpath = os\\.getenv\\('PYSDL2_DLL_PATH'\\)")
1074 "postpath = \"system\"")
1075 (("DLL\\(.*, os\\.getenv\\(\"PYSDL2_DLL_PATH\"\\)\\)")
1076 (format #f "DLL('SDL2', ['SDL2', 'SDL2-2.0', 'SDL2-2.0.0'], '~a/lib')"
1077 #$(this-package-input "sdl2"))))
1078 (substitute* "sdl2/sdlimage.py"
1079 (("os\\.getenv\\(\"PYSDL2_DLL_PATH\"\\)")
1080 (format #f "'~a/~a'" #$(this-package-input "sdl2-image")
1081 "lib/libSDL2_image.so")))
1082 (substitute* "sdl2/sdlgfx.py"
1083 (("os\\.getenv\\(\"PYSDL2_DLL_PATH\"\\)")
1084 (format #f "'~a/~a'" #$(this-package-input "sdl2-gfx")
1085 "lib/libSDL2_gfx.so")))
1086 (substitute* "sdl2/sdlmixer.py"
1087 (("os\\.getenv\\(\"PYSDL2_DLL_PATH\"\\)")
1088 (format #f "'~a/~a'" #$(this-package-input "sdl2-mixer")
1089 "lib/libSDL2_mixer.so")))
1090 (substitute* "sdl2/sdlttf.py"
1091 (("os\\.getenv\\(\"PYSDL2_DLL_PATH\"\\)")
1092 (format #f "'~a/~a'" #$(this-package-input "sdl2-ttf")
1093 "lib/libSDL2_ttf.so"))))))))
1094 (native-inputs
1095 (list python-setuptools
1096 python-wheel))
1097 (inputs
1098 (list sdl2 sdl2-image sdl2-gfx sdl2-mixer sdl2-ttf))
1099 (home-page "https://github.com/py-sdl/py-sdl2")
1100 (synopsis "Python bindings around the SDL2 game development library")
1101 (description
1102 "PySDL2 is a pure Python wrapper around the
1103@code{SDL2},@code{SDL2_mixer}, @code{SDL2_image}, @code{SDL2_ttf}, and
1104@code{SDL2_gfx} libraries. Instead of relying on C code, it uses the built-in
1105ctypes module to interface with SDL2, and provides simple Python classes and
1106wrappers for common SDL2 functionality.")
1107 (license license:cc0)))
1108
1109(define-public python-pywavefront
1110 (package
1111 (name "python-pywavefront")
1112 (version "1.3.3")
1113 (source
1114 (origin
1115 (method git-fetch)
1116 (uri (git-reference
1117 (url "https://github.com/pywavefront/PyWavefront")
1118 (commit version)))
1119 (file-name (git-file-name name version))
1120 (sha256
1121 (base32 "07r9z0dzz5xq9qlmp855mxsf9776b1ypk06nc9cf69r9d8pk8bkj"))))
1122 (build-system pyproject-build-system)
1123 (native-inputs
1124 (list python-mock
1125 python-pytest
1126 python-setuptools))
1127 (home-page "https://github.com/pywavefront/PyWavefront")
1128 (synopsis "Python library for loading Wavefront @code{.obj} files")
1129 (description
1130 "PyWavefront reads Wavefront 3D object files (@code{something.obj},
1131@code{something.obj.gz} and @code{something.mtl}) and generates interleaved
1132vertex data for each material ready for rendering.
1133
1134A simple (optional) visualization module is also provided for rendering the
1135object(s). The interleaved data can also be used by more modern renderers
1136thought VBOs or VAOs.
1137
1138Currently the most commonly used features in the specification has been
1139implemented:
1140@itemize
1141@item positions;
1142@item texture coordinates;
1143@item normals;
1144@item vertex color;
1145@item material parsing;
1146@item texture and texture parameters.
1147@end itemize")
1148 (license license:bsd-3)))
1149
1150(define-public python-qtawesome
1151 (package
1152 (name "python-qtawesome")
1153 (version "1.4.2")
1154 (source
1155 (origin
1156 (method git-fetch)
1157 (uri (git-reference
1158 (url "https://github.com/spyder-ide/qtawesome")
1159 (commit (string-append "v" version))))
1160 (file-name (git-file-name name version))
1161 (sha256
1162 (base32 "16vjnngg5hjmmbp0c2ikgc88g8q0l44n1w3wa04ga5zfhd1yhyn2"))))
1163 (build-system pyproject-build-system)
1164 (arguments
1165 (list
1166 #:test-flags
1167 ;; Actually just ::test_get_fonts_info would be better.
1168 #~(list "--ignore" "qtawesome/tests/test_qtawesome.py")
1169 #:phases
1170 #~(modify-phases %standard-phases
1171 (add-before 'check 'setenv
1172 (lambda _
1173 (setenv "QT_QPA_PLATFORM" "offscreen"))))))
1174 (propagated-inputs (list python-qtpy python-pyqt))
1175 (native-inputs (list python-pytest python-pytest-qt python-setuptools))
1176 (home-page "https://github.com/spyder-ide/qtawesome")
1177 (synopsis "FontAwesome icons in PyQt and PySide applications")
1178 (description
1179 "@code{FontAwesome} icons in @code{PyQt} and @code{PySide} applications.")
1180 (license license:expat)))
1181
1182(define-public python-vispy
1183 (package
1184 (name "python-vispy")
1185 (version "0.14.3")
1186 (source
1187 (origin
1188 (method url-fetch)
1189 (uri (pypi-uri "vispy" version))
1190 (sha256
1191 (base32 "07fkk4bdffn0iq5cprk7ydj978rqc4lvzfcs2vkzgfh8m53vifzg"))))
1192 (build-system pyproject-build-system)
1193 (arguments
1194 (list
1195 #:test-flags
1196 ;; Test requiring network access to download test data from
1197 ;; <https://raw.githubusercontent.com/vispy/demo-data/main/CONTRIBUTING.txt>.
1198 #~(list "-k" (string-append "not test_read_write_image"
1199 " and not test_wavefront"
1200 " and not test_config"))
1201 #:phases
1202 #~(modify-phases %standard-phases
1203 (add-after 'unpack 'patch-library-path
1204 (lambda _
1205 (substitute* (list "vispy/ext/egl.py"
1206 "vispy/ext/fontconfig.py"
1207 "vispy/gloo/gl/es2.py"
1208 "vispy/gloo/gl/gl2.py")
1209 (("ctypes\\.util\\.find_library\\('EGL'\\)")
1210 (format #f "'~a/~a'" #$(this-package-input "mesa")
1211 "lib/libEGL.so"))
1212 (("ctypes\\.util\\.find_library\\('GL'\\)")
1213 (format #f "'~a/~a'" #$(this-package-input "mesa")
1214 "lib/libGL.so"))
1215 (("ctypes\\.util\\.find_library\\('GLESv2'\\)")
1216 (format #f "'~a/~a'" #$(this-package-input "mesa")
1217 "lib/libGLESv2.so"))
1218 (("util\\.find_library\\('fontconfig'\\)")
1219 (format #f "'~a/~a'" #$(this-package-input "fontconfig-minimal")
1220 "lib/libfontconfig.so")))))
1221 (add-before 'check 'prepare-test-environment
1222 (lambda _
1223 ;; XXX: Check how to set DPI to run headless tests, fails when
1224 ;; DISPLAY is set.
1225 ;; E RuntimeError: could not determine DPI
1226 (setenv "HOME" "/tmp")
1227 (invoke "python" "setup.py" "build_ext" "--inplace"))))))
1228 (native-inputs
1229 (list python-cython
1230 python-pytest
1231 python-setuptools
1232 python-setuptools-scm
1233 python-wheel))
1234 (inputs
1235 (list fontconfig
1236 mesa))
1237 (propagated-inputs
1238 (list python-freetype-py
1239 python-hsluv
1240 python-kiwisolver
1241 python-meshio
1242 python-numpy
1243 python-packaging
1244 python-pillow))
1245 (home-page "http://vispy.org")
1246 (synopsis "Interactive scientific visualization in Python")
1247 (description
1248 "VisPy is a high-performance interactive 2D/3D data visualization library
1249leveraging the computational power of modern Graphics Processing Units (GPUs)
1250through the OpenGL library to display very large datasets.")
1251 (license license:bsd-3)))
1252
1253;;;
1254;;; Avoid adding new packages to the end of this file. To reduce the chances
1255;;; of a merge conflict, place them above in alphabetical order.
1256;;;