-
-
Notifications
You must be signed in to change notification settings - Fork 409
feat(Rendering): report missing view node profile imports #3449
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
daker
wants to merge
1
commit into
Kitware:master
Choose a base branch
from
daker:debug-profiles
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+79
−3
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,47 @@ | ||
| --- | ||
| title: Rendering Profiles | ||
| --- | ||
|
|
||
| # Rendering Profiles | ||
|
|
||
| VTK.js rendering profiles are side-effect imports that register rendering implementations for classes used by the scene graph. They keep applications smaller by letting you import only the rendering backends and mapper support you need. | ||
|
|
||
| ## Why profiles exist | ||
|
|
||
| Many VTK.js classes are pure pipeline or data-model classes. They only become renderable after a matching rendering profile registers the view-node overrides required by the active backend such as OpenGL or WebGPU. | ||
|
|
||
| Without the relevant profile import, VTK.js can still construct the data objects, actors, mappers, and pipeline, but rendering may fail when the scene graph asks `ViewNodeFactory` to create a backend-specific implementation for one of those classes. | ||
|
|
||
| ## Typical usage | ||
|
|
||
| Import a profile near your application entry point before creating the render window content: | ||
|
|
||
| ```js | ||
| import '@kitware/vtk.js/Rendering/Profiles/Geometry'; | ||
| ``` | ||
|
|
||
| If you need broader coverage, import the combined profile: | ||
|
|
||
| ```js | ||
| import '@kitware/vtk.js/Rendering/Profiles/All'; | ||
| ``` | ||
|
|
||
| ## Common profiles | ||
|
|
||
| - `Geometry`: core polygonal rendering support. | ||
| - `Volume`: image and volume rendering support. | ||
| - `Glyph`: glyph-specific mapper support. | ||
| - `Molecule`: sphere and stick mapper support. | ||
| - `LIC`: line integral convolution rendering support. | ||
| - `All`: imports all supported profiles. | ||
|
|
||
| ## When a profile is missing | ||
|
|
||
| A missing profile often shows up as an error from `Rendering/SceneGraph/ViewNodeFactory` saying that no implementation was found for a class and that a rendering profile is likely missing. | ||
|
|
||
| That warning means one of these is true: | ||
|
|
||
| - A built-in renderable class is being used without importing the profile that registers its rendering implementation. | ||
| - A custom renderable class has not been registered with the view-node factory. | ||
|
|
||
| If you are unsure which profile is required, importing `Rendering/Profiles/All` is the easiest way to confirm that the issue is profile-related. After that, you can narrow it back down to the smallest profile set your application needs. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.