Maniphest T72417

gpu module in CustomRenderEngine causes segfault
Confirmed, LowKNOWN ISSUE

Assigned To
None
Authored By
Enzio Probst (enzio)
Dec 13 2019, 11:58 AM
Tags
  • BF Blender
  • Python API
  • EEVEE & Viewport
Subscribers
Enzio Probst (enzio)
Germano Cavalcante (mano-wii)

Description

System Information
Operating system: Linux-5.4.2-arch1-1-x86_64-with-glibc2.29 64 Bits
Graphics card: Mesa DRI Intel(R) HD Graphics 620 (Kaby Lake GT2) Intel Open Source Technology Center 4.5 (Core Profile) Mesa 19.2.7

Blender Version
Broken: version: 2.81 (sub 16), branch: makepkg, commit date: 2019-12-04 11:32, hash: rBf1aa4d18d49d
Worked: (optional)

Short description of error
Using gpu module in CustomRenderEngine render function causes segfault

Exact steps for others to reproduce the error

  • Open attached blendfile
  • Run the python script from text editor
  • change render engine to custom
  • hit f12 (blender crashes)

Is the GPU module not suited for use in CustomRenderEngine ?
Also testet drawing a gpu.types.GPUBatch to a framebuffer object without doing matrix.push_pop(), it also caused a segfault. The matrix thing is just the simplest case to reproduce.

Related Objects

Event Timeline

Enzio Probst (enzio) created this task.Dec 13 2019, 11:58 AM
Germano Cavalcante (mano-wii) lowered the priority of this task from 90 to Low.Dec 16 2019, 8:42 PM
Germano Cavalcante (mano-wii) added projects: Add-ons (BF-Blender), GPU / Viewport.
Germano Cavalcante (mano-wii) added a subscriber: Germano Cavalcante (mano-wii).

This is a known limitation.
Rendering with F12 is done on another thread, and other threads do not have GLcontext (used by the GPU module).
We could enable a GLcontext for this case (as it is done in eevee), but this could add overhead to other external render engines, and it wouldn't solve all the problems.
A new solution to this will be planned, but it is not the priority for now. (probably during the T68977).

I will confirm the bug to keep a track.

Dalai Felinto (dfelinto) added a project: Tracker Curfew.Dec 23 2019, 1:40 PM
Jeroen Bakker (jbakker) changed the subtype of this task from "Report" to "Known Issue".Jan 7 2020, 12:36 PM
Jeroen Bakker (jbakker) removed a project: Tracker Curfew.Jan 10 2020, 1:52 PM
Germano Cavalcante (mano-wii) edited projects, added Python API; removed Add-ons (BF-Blender).Jan 10 2020, 2:28 PM
Campbell Barton (campbellbarton) moved this task from Backlog to Bugs (API) on the Python API board.Jun 18 2020, 3:29 PM
Campbell Barton (campbellbarton) moved this task from Bugs (API) to Known Issues on the Python API board.Jun 19 2020, 11:04 AM
Clément Foucault (fclem) edited projects, added EEVEE & Viewport; removed GPU / Viewport.Jun 19 2020, 10:24 PM
Clément Foucault (fclem) moved this task from Backlog to Known Issues on the EEVEE & Viewport board.Jun 27 2020, 11:43 PM