User Tools

Site Tools


doc:appunti:hardware:graphics_hardware_acceleration_raspberry_pi_2

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
doc:appunti:hardware:graphics_hardware_acceleration_raspberry_pi_2 [2022/10/18 10:51] – [How to check if V3D and/or KMS are active] niccolodoc:appunti:hardware:graphics_hardware_acceleration_raspberry_pi_2 [2022/10/20 11:15] – [Enable graphics acceleration in Chromium] niccolo
Line 7: Line 7:
 FIXME FIXME
  
-====== How to check if V3D and/or KMS are active ======+===== How to check if V3D and/or KMS are active =====
  
 **V3D** is an API provided by the Linux kernel to support 3D graphics on the **VideoCore VI** GPU (RPi 4). The software driver is actually provided in the form of a //Device Tree Overlay// which is loaded at boot time adding the following line into **/boot/config.txt**: **V3D** is an API provided by the Linux kernel to support 3D graphics on the **VideoCore VI** GPU (RPi 4). The software driver is actually provided in the form of a //Device Tree Overlay// which is loaded at boot time adding the following line into **/boot/config.txt**:
Line 29: Line 29:
 </code> </code>
  
-The **KMS** driver (Kernel Mode Setting) should be considered obsolete and replaced by V3D, infact it results **disabled** when you load the new ''vc4-kms-v3d'' overlay. You can check the following pseudofile:+The **KMS** (Kernel Mode Setting) has two different implementations. The old one (known as //Fake KMS//) was the only one available at the time of Debian 9 Stretch and it is provided byt the **vc4-fkms-v3d** overlay. Once loaded you can check its availability reading the following pseudofile (should read ''disabled'' or ''okay''):
  
 <code> <code>
Line 35: Line 35:
 </code> </code>
  
-If you want, for some obscure reasons, to enable the KMS interface (e.g. if you want to run the RaspiOS based on the old Debian 9 Stretch), then you need to load the old Fake KMS overlay, named **vc4-fkms-v3d**. In this case you will have both V3D and KMS enabled, but the software implementation in that driver is not as good.+The new overlay **vc4-kms-v3d** doesn't expose that node (which results as ''disabled''), but expose several others KMS related nodes:
  
 +<code>
 +cat /proc/device-tree/soc/hdmi@7e902000/status
 +cat /proc/device-tree/soc/hvs@7e400000/status
 +cat /proc/device-tree/soc/txp@7e004000/status
 +cat /proc/device-tree/soc/pixelvalve@7e207000/status
 +cat /proc/device-tree/soc/pixelvalve@7e807000/status
 +cat /proc/device-tree/soc/pixelvalve@7e206000/status
 +</code>
 +
 +===== Enable graphics acceleration in Chromium =====
 +
 +In Chromium you can open the page **%%chrome://gpu%%** and check the **Graphics Feature Status**, you should read:
 +
 +^ Canvas  | Hardware accelerated  |
 +^ Canvas out-of-process rasterization  | Enabled  |
 +^ Direct Rendering Display Compositor  | Disabled  |
 +^ Compositing  | Hardware accelerated  |
 +^ Multiple Raster Threads  | Enabled  |
 +^ OpenGL  | Enabled  |
 +^ Rasterization  | Hardware accelerated on all pages  |
 +^ Raw Draw  | Enabled  |
 +^ Video Decode  | Hardware accelerated  |
 +^ Video Encode  | Software only. Hardware acceleration disabled  |
 +^ Vulkan  | Disabled  |
 +^ WebGL  | Hardware accelerated  |
 +^ WebGL2  | Hardware accelerated  |
 +^ WebGPU  | Disabled  |
 +
 +Probably something is disabled, because of Chromium defaults. In that case you have to open the page **%%chrome://flags%%**, then search and set the following flags:
 +
 +^ Override software rendering list  | Overrides the built-in software rendering list and enables GPU-acceleration on unsupported system configurations.  |
 +^ Enable raw draw  | When enabled, web content will be rastered on output surface directly.  |
 +^ GPU rasterization  | Use GPU to rasterize web content.  |
 +^ Out-of-process rasterization  | FIXME Does this exists?  |
 +^ Out-of-process 2D canvas rasterization  | The rasterization of 2d canvas contents is performed in the GPU process.  |
 +^ Accelerated 2D canvas  | Enables the use of the GPU to perform 2d canvas rendering instead of using software rendering.  |
 +^ Hardware-accelerated video decode  | FIXME Does this exists?  |
 +
 +
 +===== Enable graphics acceleration in Firefox =====
  
 ===== Web References ===== ===== Web References =====
Line 43: Line 83:
   * **[[https://lemariva.com/blog/2020/08/raspberry-pi-4-video-acceleration-decode-chromium|Raspberry Pi 4: Hardware accelerated video decoding (GPU) in Chromium]]**   * **[[https://lemariva.com/blog/2020/08/raspberry-pi-4-video-acceleration-decode-chromium|Raspberry Pi 4: Hardware accelerated video decoding (GPU) in Chromium]]**
   * **[[https://forums.raspberrypi.com/viewtopic.php?t=324835|HEVC Main 10 Broken for VLC on Bullseye]]**   * **[[https://forums.raspberrypi.com/viewtopic.php?t=324835|HEVC Main 10 Broken for VLC on Bullseye]]**
 +  * **[[https://www.dedoimedo.com/computers/rpi4-ubuntu-mate-hw-video-acceleration.html|RPI4 & Ubuntu MATE - How to enable video acceleration]]**
 +  * **[[https://forums.raspberrypi.com/viewtopic.php?t=320836|(f)KMS on 64-bit Pi 4 firmware question]]**
 +  * **[[https://forums.raspberrypi.com/viewtopic.php?t=320844|Chromium/Firefox no HW acceleration]]**
  
doc/appunti/hardware/graphics_hardware_acceleration_raspberry_pi_2.txt · Last modified: 2022/10/20 11:15 by niccolo