RFR: 8314820: Unify Screen adapter ordinal logic

Marius Hanl mhanl at openjdk.org
Wed Dec 17 11:05:49 UTC 2025


On Tue, 16 Dec 2025 16:53:57 GMT, Andy Goryachev <angorya at openjdk.org> wrote:

> One thought nagged me during the review: why do we keep the ordinal (an index) when we could, in theory, keep a reference to the object? Is there a potential for misalignment, perhaps a transient one?

My guess: Because the purpose is to be an Identifier (ID) only, so that a Screen can be later mapped to a Pipeline, if needed. The `MTLPipeline` does not need that, but e.g. `D3DPipeline` does. I guess using an object therefore could be possible, but makes sense only for some pipelines still.

-------------

PR Comment: https://git.openjdk.org/jfx/pull/2009#issuecomment-3664833001


More information about the openjfx-dev mailing list