User avatar
ztealmax
Posts: 94
Joined: Sat Aug 19, 2017 5:19 pm
Contact: Website

:? - Im comfused i need som info on PI4 and GL|ES

Sun Jul 14, 2019 9:32 pm

Hi everyone im obviously totally dumb and can't search and understand what i read but i have to ask on the Raspberry pi 4 is there OpenGL|ES like on the Raspberry pi 3B+
im not talking about VC6 driver, im talking about pure GL|ES native driver not being passed tru VC6 driver or anything?

:?
/Martin

User avatar
Paeryn
Posts: 2616
Joined: Wed Nov 23, 2011 1:10 am
Location: Sheffield, England

Re: :? - Im comfused i need som info on PI4 and GL|ES

Sun Jul 14, 2019 10:27 pm

The original driver was split in two parts, the driver that did all the work of generating the shader code for the QPUs, setting up the 3D hardware and getting it to run was on the VPU. The Arm driver (what Linux used) did basic validation and caching of some data (so it could avoid the expense of querying the VPU driver where possible), then passed the calls on to the VPU driver.

Then they started writing a driver for Mesa so that everything could be controlled directly on the Arms without relying on the secret sauce of the VPU driver, this was the long running Beta OpenGL driver that you could optionally enable.

As I understand it a VPU driver for the new VC6 3D blocks has never been written, so on the RPi4 all the programming and setup of the 3D blocks has to be done on the Arm, which means using the Mesa driver. You could also write your own, the Mesa code is available to see how that does it but it'll be better when (if) they release documentation of the 3D blocks like they did for the VC4's.
She who travels light — forgot something.

User avatar
ztealmax
Posts: 94
Joined: Sat Aug 19, 2017 5:19 pm
Contact: Website

Re: :? - Im comfused i need som info on PI4 and GL|ES

Mon Jul 15, 2019 6:49 am

Paeryn wrote:
Sun Jul 14, 2019 10:27 pm
The original driver was split in two parts, the driver that did all the work of generating the shader code for the QPUs, setting up the 3D hardware and getting it to run was on the VPU. The Arm driver (what Linux used) did basic validation and caching of some data (so it could avoid the expense of querying the VPU driver where possible), then passed the calls on to the VPU driver.

Then they started writing a driver for Mesa so that everything could be controlled directly on the Arms without relying on the secret sauce of the VPU driver, this was the long running Beta OpenGL driver that you could optionally enable.

As I understand it a VPU driver for the new VC6 3D blocks has never been written, so on the RPi4 all the programming and setup of the 3D blocks has to be done on the Arm, which means using the Mesa driver. You could also write your own, the Mesa code is available to see how that does it but it'll be better when (if) they release documentation of the 3D blocks like they did for the VC4's.
So if i understand this correctly it would be possible now to compile OpenGL|ES games using mesa, but not VC6 is this correct? And thank you for repsonding

User avatar
Gavinmc42
Posts: 3482
Joined: Wed Aug 28, 2013 3:31 am

Re: :? - Im comfused i need som info on PI4 and GL|ES

Mon Jul 15, 2019 7:09 am

Confused? join the club ;)
A search will not find much yet on this.
Some are further along than others.

With the Pi4 OpenGL will be the starting point.
The source for that open driver is in the mesa code.

Not sure if or when VC6 OpenGLES/VG stuff will show up.

I already run OpenGL games, some are ok, some need work and some just don't run yet.
Grab the source for working ones and figure them out?

Start with the mesa demo examples, those are mostly single C files and easy to read.
I did get them working in Gentoo64 and 3B+, I have yet to get them working on a Pi4.

Also look on the baremetal posts, clues are poping up there too.
I'm dancing on Rainbows.
Raspberries are not Apples or Oranges

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 23083
Joined: Sat Jul 30, 2011 7:41 pm

Re: :? - Im comfused i need som info on PI4 and GL|ES

Mon Jul 15, 2019 9:22 am

ztealmax wrote:
Mon Jul 15, 2019 6:49 am
Paeryn wrote:
Sun Jul 14, 2019 10:27 pm
The original driver was split in two parts, the driver that did all the work of generating the shader code for the QPUs, setting up the 3D hardware and getting it to run was on the VPU. The Arm driver (what Linux used) did basic validation and caching of some data (so it could avoid the expense of querying the VPU driver where possible), then passed the calls on to the VPU driver.

Then they started writing a driver for Mesa so that everything could be controlled directly on the Arms without relying on the secret sauce of the VPU driver, this was the long running Beta OpenGL driver that you could optionally enable.

As I understand it a VPU driver for the new VC6 3D blocks has never been written, so on the RPi4 all the programming and setup of the 3D blocks has to be done on the Arm, which means using the Mesa driver. You could also write your own, the Mesa code is available to see how that does it but it'll be better when (if) they release documentation of the 3D blocks like they did for the VC4's.
So if i understand this correctly it would be possible now to compile OpenGL|ES games using mesa, but not VC6 is this correct? And thank you for repsonding
The MESA drivers now give a much more standard API to the 3D. They talk to the GPU (VC6) directly from ARM space. The final rendered bitmaps are still presented to the final compositor using dispmanx so runs n the GPU firmware, but this is abstracted away and uses the standard DRM interface - this is what we call Fake KMS. So its should all now be standard API's to do all 3D graphics, and in fact this is how X is now rendered - via the MESA drivers and DRM.
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed. Here's an example...
"My grief counseller just died, luckily, he was so good, I didn't care."

Return to “OpenGLES”