AcademySoftwareFoundation / AcademySoftwareFoundation/OpenColorIO

Add an easier way to get both active & inactive views for a display

Open
#1,824 2 comments 1 reaction 0 assignees View on GitHub
good first issue help wanted
Dominant language
C++
Stars
2.1k
Forks
503
PR merge metrics
No merged PRs in 30d

Description

In OCIO v1, the Config getViews(display) method returned all views. This was considered a bug (per issue #67) and a fix was attempted in closed PR #324 and then finally fixed in PR #875 (as part of OCIO v2).

As a result, in OCIO 2.x, getViews only returns the active views. This is usually what an application would want.

However in some situations it is useful to get all the views (active & inactive). Currently there is this API to do that:
```
int getNumViews(ViewType type, const char * display) const;
const char * getView(ViewType type, const char * display, int index) const;
```
but it requires iterating over both the shared and per-display views for a display. It would be nice to have the equivalent of getNumDisplaysAll and getDisplayAll for views.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.