prism-viewer 1.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- prism_viewer-1.0.0/LICENSE +21 -0
- prism_viewer-1.0.0/PKG-INFO +435 -0
- prism_viewer-1.0.0/README.md +420 -0
- prism_viewer-1.0.0/pyproject.toml +56 -0
- prism_viewer-1.0.0/setup.cfg +4 -0
- prism_viewer-1.0.0/src/prism/__init__.py +3 -0
- prism_viewer-1.0.0/src/prism/core/__init__.py +2 -0
- prism_viewer-1.0.0/src/prism/core/frame_cache.py +56 -0
- prism_viewer-1.0.0/src/prism/core/frame_service.py +71 -0
- prism_viewer-1.0.0/src/prism/core/frame_source.py +17 -0
- prism_viewer-1.0.0/src/prism/core/ocio_processor.py +89 -0
- prism_viewer-1.0.0/src/prism/core/source_models.py +209 -0
- prism_viewer-1.0.0/src/prism/core/ui_tokens.py +40 -0
- prism_viewer-1.0.0/src/prism/core/viewer_state.py +70 -0
- prism_viewer-1.0.0/src/prism/io/__init__.py +2 -0
- prism_viewer-1.0.0/src/prism/io/image_loader.py +148 -0
- prism_viewer-1.0.0/src/prism/io/movie_loader.py +247 -0
- prism_viewer-1.0.0/src/prism/io/ocio_config.py +120 -0
- prism_viewer-1.0.0/src/prism/io/sequence_loader.py +61 -0
- prism_viewer-1.0.0/src/prism/io/source_detect.py +39 -0
- prism_viewer-1.0.0/src/prism/main.py +31 -0
- prism_viewer-1.0.0/src/prism/ui/__init__.py +2 -0
- prism_viewer-1.0.0/src/prism/ui/assets/icons/app_icon.ico +0 -0
- prism_viewer-1.0.0/src/prism/ui/assets/icons/app_icon.png +0 -0
- prism_viewer-1.0.0/src/prism/ui/assets/images/about_banner.png +0 -0
- prism_viewer-1.0.0/src/prism/ui/compare_view.py +1322 -0
- prism_viewer-1.0.0/src/prism/ui/context_variables_dock.py +59 -0
- prism_viewer-1.0.0/src/prism/ui/context_variables_panel.py +183 -0
- prism_viewer-1.0.0/src/prism/ui/main_window.py +2288 -0
- prism_viewer-1.0.0/src/prism/ui/status_formatters.py +58 -0
- prism_viewer-1.0.0/src/prism/ui/view_math.py +255 -0
- prism_viewer-1.0.0/src/prism_viewer.egg-info/PKG-INFO +435 -0
- prism_viewer-1.0.0/src/prism_viewer.egg-info/SOURCES.txt +47 -0
- prism_viewer-1.0.0/src/prism_viewer.egg-info/dependency_links.txt +1 -0
- prism_viewer-1.0.0/src/prism_viewer.egg-info/entry_points.txt +2 -0
- prism_viewer-1.0.0/src/prism_viewer.egg-info/requires.txt +5 -0
- prism_viewer-1.0.0/src/prism_viewer.egg-info/top_level.txt +1 -0
- prism_viewer-1.0.0/tests/test_compare_view_logic.py +120 -0
- prism_viewer-1.0.0/tests/test_frame_service.py +67 -0
- prism_viewer-1.0.0/tests/test_main_entrypoint.py +102 -0
- prism_viewer-1.0.0/tests/test_main_window_logic.py +161 -0
- prism_viewer-1.0.0/tests/test_movie_loader.py +70 -0
- prism_viewer-1.0.0/tests/test_ocio_config.py +172 -0
- prism_viewer-1.0.0/tests/test_ocio_processor.py +148 -0
- prism_viewer-1.0.0/tests/test_sequence_loader.py +62 -0
- prism_viewer-1.0.0/tests/test_source_detect.py +46 -0
- prism_viewer-1.0.0/tests/test_status_formatters.py +78 -0
- prism_viewer-1.0.0/tests/test_ui_tokens.py +14 -0
- prism_viewer-1.0.0/tests/test_view_math_geometry.py +105 -0
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Jean-Francois Bouchard
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,435 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: prism-viewer
|
|
3
|
+
Version: 1.0.0
|
|
4
|
+
Summary: OCIO still-image viewer for A/B comparison
|
|
5
|
+
License-Expression: MIT
|
|
6
|
+
Requires-Python: >=3.11
|
|
7
|
+
Description-Content-Type: text/markdown
|
|
8
|
+
License-File: LICENSE
|
|
9
|
+
Requires-Dist: PySide6
|
|
10
|
+
Requires-Dist: opencv-python
|
|
11
|
+
Requires-Dist: OpenImageIO
|
|
12
|
+
Requires-Dist: OpenColorIO
|
|
13
|
+
Requires-Dist: numpy
|
|
14
|
+
Dynamic: license-file
|
|
15
|
+
|
|
16
|
+
# Prism
|
|
17
|
+
|
|
18
|
+

|
|
19
|
+
### (Pipeline Review and Image State Monitor)
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
Prism is a lightweight OCIO image viewer built for fast visual inspection, transform validation, and A/B comparison workflows.
|
|
23
|
+
|
|
24
|
+
It was created from a very practical need: quickly loading images, testing colorspace transforms, comparing outputs, and debugging OCIO behavior without having to launch a full compositing or grading application.
|
|
25
|
+
|
|
26
|
+
Prism focuses on still-image workflows and immediate visual feedback:
|
|
27
|
+
|
|
28
|
+
* compare two images side-by-side
|
|
29
|
+
* wipe between transforms
|
|
30
|
+
* inspect differences
|
|
31
|
+
* validate looks and context variables
|
|
32
|
+
* probe pixel values
|
|
33
|
+
* and quickly iterate on OCIO decisions
|
|
34
|
+
|
|
35
|
+
The goal is not to replace tools like Nuke, RV, or Resolve.
|
|
36
|
+
|
|
37
|
+
The goal is to provide a focused, lightweight environment for color pipeline inspection and experimentation, especially during look development, pipeline debugging, config validation, and day-to-day production support.
|
|
38
|
+
|
|
39
|
+
Built with:
|
|
40
|
+
|
|
41
|
+
* PySide6
|
|
42
|
+
* OpenColorIO
|
|
43
|
+
* OpenImageIO
|
|
44
|
+
* NumPy
|
|
45
|
+
|
|
46
|
+

|
|
47
|
+
|
|
48
|
+
---
|
|
49
|
+
|
|
50
|
+
# Why Prism Exists
|
|
51
|
+
|
|
52
|
+
Many OCIO workflows still rely on launching large DCC applications just to validate a transform, compare two outputs, or debug context-dependent behavior.
|
|
53
|
+
|
|
54
|
+
Prism was built to reduce that friction.
|
|
55
|
+
|
|
56
|
+
It provides a fast standalone environment for inspecting color behavior directly, with minimal setup and immediate visual feedback.
|
|
57
|
+
|
|
58
|
+
Whether you're:
|
|
59
|
+
|
|
60
|
+
* validating an OCIO config
|
|
61
|
+
* checking a display transform
|
|
62
|
+
* comparing renders
|
|
63
|
+
* debugging context variables
|
|
64
|
+
* verifying looks
|
|
65
|
+
* or simply inspecting image data
|
|
66
|
+
|
|
67
|
+
Prism aims to make that process faster and more direct.
|
|
68
|
+
|
|
69
|
+
---
|
|
70
|
+
|
|
71
|
+
# Features
|
|
72
|
+
|
|
73
|
+
* Load and compare two images simultaneously
|
|
74
|
+
* Apply independent OCIO transforms to A and B
|
|
75
|
+
* Compare images using Split, Wipe, Full, and Diff modes
|
|
76
|
+
* Inspect pixel values directly in the viewer HUD
|
|
77
|
+
* Adjust exposure and luminance interactively
|
|
78
|
+
* Edit OCIO context variables live
|
|
79
|
+
* Navigate synchronized A/B views
|
|
80
|
+
* Toggle transform bypass per image
|
|
81
|
+
* Use EXR, DPX, JPG, PNG, TIFF, and other common formats
|
|
82
|
+
* Built-in diagnostics window for environment validation
|
|
83
|
+
|
|
84
|
+
---
|
|
85
|
+
|
|
86
|
+
# Requirements
|
|
87
|
+
|
|
88
|
+
* Python 3.11+
|
|
89
|
+
* Runtime packages:
|
|
90
|
+
|
|
91
|
+
* `PySide6`
|
|
92
|
+
* `OpenImageIO`
|
|
93
|
+
* `OpenColorIO`
|
|
94
|
+
* `numpy`
|
|
95
|
+
|
|
96
|
+
---
|
|
97
|
+
|
|
98
|
+
# Install
|
|
99
|
+
|
|
100
|
+
From repository root:
|
|
101
|
+
|
|
102
|
+
```powershell
|
|
103
|
+
python -m pip install -e .
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
---
|
|
107
|
+
|
|
108
|
+
# Launch
|
|
109
|
+
|
|
110
|
+
```powershell
|
|
111
|
+
prism
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
If the command is not found, activate your virtual environment first and retry.
|
|
115
|
+
|
|
116
|
+
---
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
# Quick Start
|
|
120
|
+
|
|
121
|
+

|
|
122
|
+
|
|
123
|
+
|
|
124
|
+
1. Open image A from `File -> Open Image A...`
|
|
125
|
+
2. Open image B from `File -> Open Image B...`
|
|
126
|
+
3. Load an OCIO config from `File -> Open OCIO Config...`
|
|
127
|
+
|
|
128
|
+

|
|
129
|
+
|
|
130
|
+
4. Select Input and Output colorspaces independently for A and B
|
|
131
|
+
5. Optionally select a Look
|
|
132
|
+
6. Switch compare modes (`Split`, `Wipe`, `Full (A)`, `Full (B)` `Diff`)
|
|
133
|
+
|
|
134
|
+

|
|
135
|
+
|
|
136
|
+
7. Hover over the viewer to inspect pixel values in the footer HUD
|
|
137
|
+
|
|
138
|
+

|
|
139
|
+
|
|
140
|
+
Prism also supports drag-and-drop for images and OCIO configs.
|
|
141
|
+
|
|
142
|
+
---
|
|
143
|
+
|
|
144
|
+
# Compare Modes
|
|
145
|
+
|
|
146
|
+
## Split
|
|
147
|
+
|
|
148
|
+
Shows A and B side-by-side.
|
|
149
|
+
|
|
150
|
+
Useful for:
|
|
151
|
+
|
|
152
|
+
* framing comparisons
|
|
153
|
+
* look validation
|
|
154
|
+
* general A/B review
|
|
155
|
+
|
|
156
|
+

|
|
157
|
+
|
|
158
|
+
---
|
|
159
|
+
|
|
160
|
+
## Wipe
|
|
161
|
+
|
|
162
|
+
Displays A/B across an interactive divider.
|
|
163
|
+
|
|
164
|
+
Use the wipe handle to inspect transitions and subtle image differences interactively.
|
|
165
|
+
|
|
166
|
+

|
|
167
|
+
|
|
168
|
+
---
|
|
169
|
+
|
|
170
|
+
## Full
|
|
171
|
+
|
|
172
|
+
Displays only the currently selected side (`A` or `B`).
|
|
173
|
+
|
|
174
|
+
Useful for focused single-image inspection while preserving the compare setup.
|
|
175
|
+
|
|
176
|
+

|
|
177
|
+
|
|
178
|
+
---
|
|
179
|
+
|
|
180
|
+
## Diff
|
|
181
|
+
|
|
182
|
+
Displays grayscale absolute difference between overlapping regions.
|
|
183
|
+
|
|
184
|
+
Brighter values indicate stronger differences.
|
|
185
|
+
|
|
186
|
+
Useful for:
|
|
187
|
+
|
|
188
|
+
* transform validation
|
|
189
|
+
* render verification
|
|
190
|
+
* subtle change detection
|
|
191
|
+
|
|
192
|
+

|
|
193
|
+
|
|
194
|
+
---
|
|
195
|
+
|
|
196
|
+
# OCIO Context Variables
|
|
197
|
+
|
|
198
|
+
Prism can detect and expose OCIO context variables directly from the loaded config.
|
|
199
|
+
|
|
200
|
+
Open from:
|
|
201
|
+
|
|
202
|
+
* `View -> OCIO Context Variables`
|
|
203
|
+
* Hotkey: `E`
|
|
204
|
+
|
|
205
|
+
Behavior:
|
|
206
|
+
|
|
207
|
+
* Hidden by default
|
|
208
|
+
* Dynamically rebuilds from the loaded config
|
|
209
|
+
* Updates processing live as values change
|
|
210
|
+
* Can be docked or undocked
|
|
211
|
+
* Persists current values while visible or hidden
|
|
212
|
+
|
|
213
|
+
This is especially useful for:
|
|
214
|
+
|
|
215
|
+
* shot-based transforms
|
|
216
|
+
* context-driven looks
|
|
217
|
+
* sequence-dependent processing
|
|
218
|
+
* debugging OCIO environment behavior
|
|
219
|
+
|
|
220
|
+

|
|
221
|
+
|
|
222
|
+

|
|
223
|
+
|
|
224
|
+
---
|
|
225
|
+
|
|
226
|
+
# Viewer Controls
|
|
227
|
+
|
|
228
|
+
## Exposure and Luminance
|
|
229
|
+
|
|
230
|
+
Interactive controls allow quick image inspection without modifying source data.
|
|
231
|
+
|
|
232
|
+
Useful for:
|
|
233
|
+
|
|
234
|
+
* shadow inspection
|
|
235
|
+
* highlight clipping checks
|
|
236
|
+
* transform debugging
|
|
237
|
+
* general image evaluation
|
|
238
|
+
|
|
239
|
+

|
|
240
|
+
|
|
241
|
+
---
|
|
242
|
+
|
|
243
|
+
## Background Presets
|
|
244
|
+
|
|
245
|
+
Open from:
|
|
246
|
+
|
|
247
|
+
* `View -> Background`
|
|
248
|
+
|
|
249
|
+
Presets:
|
|
250
|
+
|
|
251
|
+
* Black
|
|
252
|
+
* Dark Gray
|
|
253
|
+
* Mid Gray
|
|
254
|
+
* Light Gray
|
|
255
|
+
|
|
256
|
+
Useful when image edges become difficult to read against the viewer background.
|
|
257
|
+
|
|
258
|
+

|
|
259
|
+
|
|
260
|
+
---
|
|
261
|
+
|
|
262
|
+
# Diagnostics
|
|
263
|
+
|
|
264
|
+
Prism includes a diagnostics window for quickly validating runtime dependencies and OCIO environment state.
|
|
265
|
+
|
|
266
|
+
Includes:
|
|
267
|
+
|
|
268
|
+
* Prism version
|
|
269
|
+
* Python version
|
|
270
|
+
* Qt / PySide version
|
|
271
|
+
* NumPy version
|
|
272
|
+
* OpenImageIO version
|
|
273
|
+
* OpenColorIO version
|
|
274
|
+
* Active OCIO config
|
|
275
|
+
* Platform information
|
|
276
|
+
|
|
277
|
+
Useful for:
|
|
278
|
+
|
|
279
|
+
* support,
|
|
280
|
+
* debugging,
|
|
281
|
+
* pipeline validation,
|
|
282
|
+
* environment troubleshooting.
|
|
283
|
+
|
|
284
|
+

|
|
285
|
+

|
|
286
|
+
|
|
287
|
+
---
|
|
288
|
+
|
|
289
|
+
# Typical Workflows
|
|
290
|
+
|
|
291
|
+
## A/B Grade Validation
|
|
292
|
+
|
|
293
|
+
1. Load image A and B
|
|
294
|
+
2. Load an OCIO config
|
|
295
|
+
3. Configure Input and Output transforms
|
|
296
|
+
4. Start in `Split`
|
|
297
|
+
5. Move to `Wipe` for edge comparison
|
|
298
|
+
6. Use `Diff` to isolate subtle changes
|
|
299
|
+
|
|
300
|
+
---
|
|
301
|
+
|
|
302
|
+
## Single Image Inspection
|
|
303
|
+
|
|
304
|
+
1. Load image A
|
|
305
|
+
2. Configure transforms
|
|
306
|
+
3. Switch to `Full`
|
|
307
|
+
4. Inspect pixel values and channels
|
|
308
|
+
5. Adjust exposure and luminance interactively
|
|
309
|
+
|
|
310
|
+
---
|
|
311
|
+
|
|
312
|
+
## Context-Based Look Debugging
|
|
313
|
+
|
|
314
|
+
1. Load image and OCIO config
|
|
315
|
+
2. Open `View -> OCIO Context Variables`
|
|
316
|
+
3. Modify context values
|
|
317
|
+
4. Observe updates live in the viewer
|
|
318
|
+
|
|
319
|
+
---
|
|
320
|
+
|
|
321
|
+
# Hotkeys
|
|
322
|
+
|
|
323
|
+
* `F` Fit to Window
|
|
324
|
+
* `H` Show/Hide Hotkeys dialog
|
|
325
|
+
* `E` Toggle OCIO Context Variables dock
|
|
326
|
+
* `Tab` Switch active side A/B
|
|
327
|
+
* `Right` / `PageDown` Next frame
|
|
328
|
+
* `Left` / `PageUp` Previous frame
|
|
329
|
+
* `Up` / `Down` Change focused Input/Output item
|
|
330
|
+
* `R` Toggle Red solo / RGB
|
|
331
|
+
* `G` Toggle Green solo / RGB
|
|
332
|
+
* `B` Toggle Blue solo / RGB
|
|
333
|
+
* `Z` Restore RGB
|
|
334
|
+
* `1 / 2 / 3 / 4 / 5`
|
|
335
|
+
|
|
336
|
+
* Split
|
|
337
|
+
* Wipe
|
|
338
|
+
* Full (A)
|
|
339
|
+
* Full (B)
|
|
340
|
+
* Diff
|
|
341
|
+
* `Right Click + Drag` Pan
|
|
342
|
+
|
|
343
|
+

|
|
344
|
+
|
|
345
|
+
---
|
|
346
|
+
|
|
347
|
+
# Sample Assets
|
|
348
|
+
|
|
349
|
+
Prism includes sample files to validate setup quickly:
|
|
350
|
+
|
|
351
|
+
* Sample images: `samples/images/`
|
|
352
|
+
* Sample OCIO config: `samples/ocio_config/`
|
|
353
|
+
|
|
354
|
+
Quick smoke test:
|
|
355
|
+
|
|
356
|
+
1. Launch `prism`
|
|
357
|
+
2. Load image A and B from `samples/images/`
|
|
358
|
+
3. Load config from `samples/ocio_config/`
|
|
359
|
+
4. Switch between `Split`, `Wipe`, `Full (A)`, `Full (B)`, and `Diff`
|
|
360
|
+
|
|
361
|
+
---
|
|
362
|
+
|
|
363
|
+
# Troubleshooting
|
|
364
|
+
|
|
365
|
+
## `prism` command not found
|
|
366
|
+
|
|
367
|
+
Activate the intended virtual environment and reinstall from repository root:
|
|
368
|
+
|
|
369
|
+
```powershell
|
|
370
|
+
python -m pip install -e .
|
|
371
|
+
```
|
|
372
|
+
|
|
373
|
+
---
|
|
374
|
+
|
|
375
|
+
## OCIO config fails to load
|
|
376
|
+
|
|
377
|
+
* Confirm `OpenColorIO` is installed in the active environment
|
|
378
|
+
* Confirm the selected file is a valid `.ocio` config
|
|
379
|
+
* If loading is canceled intentionally, Prism preserves current state
|
|
380
|
+
|
|
381
|
+
---
|
|
382
|
+
|
|
383
|
+
## EXR or DPX images fail to load
|
|
384
|
+
|
|
385
|
+
Prism uses OpenImageIO fallback support for formats that may not be available through Qt directly.
|
|
386
|
+
|
|
387
|
+
Verify:
|
|
388
|
+
|
|
389
|
+
* `OpenImageIO` is installed
|
|
390
|
+
* the active environment can import it successfully
|
|
391
|
+
|
|
392
|
+
---
|
|
393
|
+
|
|
394
|
+
## Movie source issues
|
|
395
|
+
|
|
396
|
+
Movie playback depends on optional backend availability such as:
|
|
397
|
+
|
|
398
|
+
* `opencv-python`
|
|
399
|
+
* `imageio[ffmpeg]`
|
|
400
|
+
|
|
401
|
+
Still-image workflows remain fully functional without them.
|
|
402
|
+
|
|
403
|
+
---
|
|
404
|
+
|
|
405
|
+
# Known Limitations
|
|
406
|
+
|
|
407
|
+
* Movie workflows remain backend/environment dependent
|
|
408
|
+
* Some EXR/DPX workflows rely on OpenImageIO fallback support
|
|
409
|
+
* Windows taskbar icon refresh may lag behind icon updates until Explorer refreshes shell cache
|
|
410
|
+
|
|
411
|
+
---
|
|
412
|
+
|
|
413
|
+
# Planned Features
|
|
414
|
+
|
|
415
|
+
* Waveform Monitor
|
|
416
|
+
* Vectorscope
|
|
417
|
+
* Chromaticity Diagram and gamut visualization
|
|
418
|
+
* Transform breakdown visualization
|
|
419
|
+
* LUT plotting
|
|
420
|
+
* Nuke integration
|
|
421
|
+
* Resolve integration
|
|
422
|
+
* More Display/View support
|
|
423
|
+
|
|
424
|
+
---
|
|
425
|
+
|
|
426
|
+
## Architecture and Developer Docs
|
|
427
|
+
|
|
428
|
+
See [docs/README.md](./docs/README.md) for subsystem and architecture documentation:
|
|
429
|
+
|
|
430
|
+
- [Architecture](./docs/architecture.md)
|
|
431
|
+
- [Core](./docs/core.md)
|
|
432
|
+
- [I/O](./docs/io.md)
|
|
433
|
+
- [UI](./docs/ui.md)
|
|
434
|
+
- [OCIO Context](./docs/ocio-context.md)
|
|
435
|
+
- [Packaging](./docs/packaging.md)
|