-
-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Add basic docs explaining what asset processing is and where to look #15058
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
Add basic docs explaining what asset processing is and where to look #15058
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good work! This is good to go once comments are addressed.
Co-authored-by: Carter Anderson <[email protected]>
//! To set the default asset processor for a given extension, use [`AssetProcessor::set_default_processor`]. | ||
//! In most cases, these methods will be called directly on [`App`](bevy_app::App) using the [`AssetApp`](crate::AssetApp) extension trait. | ||
//! | ||
//! If a default asset processor is set, assets with a matching extension will be processed using that processor before loading. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, I couldn't figure out how to load an asset with an arbitrary processor :(
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From code? Not possible afaik. You have to use meta files.
//! To set the default asset processor for a given extension, use [`AssetProcessor::set_default_processor`]. | ||
//! In most cases, these methods will be called directly on [`App`](bevy_app::App) using the [`AssetApp`](crate::AssetApp) extension trait. | ||
//! | ||
//! If a default asset processor is set, assets with a matching extension will be processed using that processor before loading. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From code? Not possible afaik. You have to use meta files.
Objective
Asset processing (added as part of #8624) is a powerful, high-impact feature, but has been widely underused (and underdeveloped) due to poor developer understanding.
Solution
In this PR, I've documented what asset processing is, why it's useful, and pointed users to the two primary entry points.
While I would like substantially more involved practical examples for how to perform common asset-processing tasks, I've split them out from this PR for ease of review (and actually submitting this for review before the weekend).
We should add bread crumbs from the module docs to these docs, but whether we add that here or in #15056 depends on which gets merged first.