Add support for OpenPGL 0.5.0 #106861

Merged
Sebastian Parborg merged 1 commits from :openpgl5 into main 2023-04-13 11:44:47 +02:00

Some functions changed slightly for this non beta release.
No functional changes though as we didn't use what was removed.

Some functions changed slightly for this non beta release. No functional changes though as we didn't use what was removed.
Sebastian Parborg added the
Interest
Cycles
label 2023-04-12 16:06:48 +02:00
Sebastian Parborg added 1 commit 2023-04-12 16:07:01 +02:00
buildbot/vexp-code-patch-coordinator Build done. Details
9ed6647edb
Add support for OpenPGL 0.5.0
Some functions changed slightly for this non beta release.
No functional changes though as we didn't use what was removed.
Sebastian Parborg requested review from Brecht Van Lommel 2023-04-12 16:07:43 +02:00
Sebastian Parborg requested review from Sergey Sharybin 2023-04-12 16:07:43 +02:00
Author
Member

BTW, should we perhaps cherry pick this for the 3.5.1 release?
OpenPGL 0.5.0 seems to be the first non beta release of the software, so I'm guessing that is what most distros will package eventually.

BTW, should we perhaps cherry pick this for the 3.5.1 release? OpenPGL 0.5.0 seems to be the first non beta release of the software, so I'm guessing that is what most distros will package eventually.
Author
Member

@blender-bot build

@blender-bot build
Sebastian Parborg added
Module
Render & Cycles
and removed
Interest
Cycles
labels 2023-04-12 16:30:57 +02:00
Sergey Sharybin requested changes 2023-04-12 17:34:56 +02:00
Sergey Sharybin left a comment
Owner

The version kind of works for now, but on a logic level it is wrong: if the major version 1.0 is released tomorrow (hypothetically) without changing this part of the API the wrong code path will be taken. Strictly speaking this needs to be OPENPGL_VERSION_MAJOR >= 1 || OPENPGL_VERSION_MINOR >= 5.

For the cherry-pick the biggest concern I have is that it is unclear how well tested the change is, and how well Cycles works with the new OpenPGL release.

The version kind of works for now, but on a logic level it is wrong: if the major version 1.0 is released tomorrow (hypothetically) without changing this part of the API the wrong code path will be taken. Strictly speaking this needs to be `OPENPGL_VERSION_MAJOR >= 1 || OPENPGL_VERSION_MINOR >= 5`. For the cherry-pick the biggest concern I have is that it is unclear how well tested the change is, and how well Cycles works with the new OpenPGL release.
Author
Member

The version kind of works for now, but on a logic level it is wrong: if the major version 1.0 is released tomorrow (hypothetically) without changing this part of the API the wrong code path will be taken. Strictly speaking this needs to be OPENPGL_VERSION_MAJOR >= 1 || OPENPGL_VERSION_MINOR >= 5.

I actually had that initially, but then I looked at what the current checks in the code does and they only check for the minor version. (Which I agree is wrong, but I didn't want to go against the implicit standard that is currently in the code)

Perhaps I should create a follow up commit in this PR that fixes all the remaining checks as well?

For the cherry-pick the biggest concern I have is that it is unclear how well tested the change is, and how well Cycles works with the new OpenPGL release.

Are there any built in test for this?
All cycles tests seems to pass on my computer with 0.5.0. But I don't know if you are testing PGL specifically in any of them right now.

> The version kind of works for now, but on a logic level it is wrong: if the major version 1.0 is released tomorrow (hypothetically) without changing this part of the API the wrong code path will be taken. Strictly speaking this needs to be `OPENPGL_VERSION_MAJOR >= 1 || OPENPGL_VERSION_MINOR >= 5`. I actually had that initially, but then I looked at what the current checks in the code does and they only check for the minor version. (Which I agree is wrong, but I didn't want to go against the implicit standard that is currently in the code) Perhaps I should create a follow up commit in this PR that fixes all the remaining checks as well? > For the cherry-pick the biggest concern I have is that it is unclear how well tested the change is, and how well Cycles works with the new OpenPGL release. Are there any built in test for this? All cycles tests seems to pass on my computer with 0.5.0. But I don't know if you are testing PGL specifically in any of them right now.

I actually had that initially, but then I looked at what the current checks in the code does and they only check for the minor version. (Which I agree is wrong, but I didn't want to go against the implicit standard that is currently in the code)

Perhaps I should create a follow up commit in this PR that fixes all the remaining checks as well?

I see. For now it is indeed more consistent to follow the MINOR check only.

For the more clear checks we probably should introduce something like OPENPGL_VERSION_AT_LEAST(...) in the util/guiding.h. It will make checks in the code be much easier to understand.

Are there any built in test for this?

There are some tests, but I am not sure if things like #104329 have a dedicated test.
There is also difference between a handful automated tests, and actual real world usage. The latter one we simply do not have any feedback yet.

That being said, fixing compilation error is fine for the corrective release, granted it is straightforward change. Is more of setting an expectation: while Blender will be able to be compiled, we can not guarantee it works same reliable as the official Blender release.

> I actually had that initially, but then I looked at what the current checks in the code does and they only check for the minor version. (Which I agree is wrong, but I didn't want to go against the implicit standard that is currently in the code) > > Perhaps I should create a follow up commit in this PR that fixes all the remaining checks as well? I see. For now it is indeed more consistent to follow the MINOR check only. For the more clear checks we probably should introduce something like `OPENPGL_VERSION_AT_LEAST(...)` in the `util/guiding.h`. It will make checks in the code be much easier to understand. > Are there any built in test for this? There are some tests, but I am not sure if things like #104329 have a dedicated test. There is also difference between a handful automated tests, and actual real world usage. The latter one we simply do not have any feedback yet. That being said, fixing compilation error is fine for the corrective release, granted it is straightforward change. Is more of setting an expectation: while Blender will be able to be compiled, we can not guarantee it works same reliable as the official Blender release.
Sergey Sharybin approved these changes 2023-04-12 18:20:14 +02:00
Sergey Sharybin left a comment
Owner

And because there is no easy way to write a reply in the conversation and approve the code at the same time., here is a dedicated comment from the code review section.

And because there is no easy way to write a reply in the conversation and approve the code at the same time., here is a dedicated comment from the code review section.
Brecht Van Lommel requested review from Ghost Team 2023-04-12 20:55:17 +02:00
First-time contributor

@ZedDB, your patch looks exactly like the one I wanted to push tomorrow :)

@Sergey as soon as the API is more stable and all Blender dependency builds are upgraded to >= 0.5 I would like to remove some of the version ifdef and bump the minimum required Open PGL version.

@ZedDB, your patch looks exactly like the one I wanted to push tomorrow :) @Sergey as soon as the API is more stable and all Blender dependency builds are upgraded to >= 0.5 I would like to remove some of the version ifdef and bump the minimum required Open PGL version.

@Sergey as soon as the API is more stable and all Blender dependency builds are upgraded to >= 0.5 I would like to remove some of the version ifdef and bump the minimum required Open PGL version.

Sure, once we bump requirement we can get rid of the current checks.
But I can imagine that in the future we'll want to be able to check version in the future, with the new development of OpenPGL. For that I'd really prefer having more explicit comparison than relying on an implicit match of the major version.

> @Sergey as soon as the API is more stable and all Blender dependency builds are upgraded to >= 0.5 I would like to remove some of the version ifdef and bump the minimum required Open PGL version. Sure, once we bump requirement we can get rid of the current checks. But I can imagine that in the future we'll want to be able to check version in the future, with the new development of OpenPGL. For that I'd really prefer having more explicit comparison than relying on an implicit match of the major version.
Sebastian Herholz approved these changes 2023-04-13 10:19:40 +02:00
Sebastian Herholz left a comment
Member

This looks good.

This looks good.
Sebastian Parborg merged commit aa6e95281f into main 2023-04-13 11:44:47 +02:00
Sebastian Parborg deleted branch openpgl5 2023-04-13 11:44:48 +02:00
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
4 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#106861
No description provided.