mirror of
https://github.com/gfx-rs/wgpu.git
synced 2026-04-22 03:02:01 -04:00
Link to TextureBlitterBuilder from TextureBlitter::new (#7003)
This commit is contained in:
@@ -86,7 +86,7 @@ By @brodycj in [#6925](https://github.com/gfx-rs/wgpu/pull/6925).
|
||||
|
||||
### Documentation
|
||||
|
||||
- Improved documentation around pipeline caches. By @DJMcNab in [#6978](https://github.com/gfx-rs/wgpu/pull/6978).
|
||||
- Improved documentation around pipeline caches and `TextureBlitter`. By @DJMcNab in [#6978](https://github.com/gfx-rs/wgpu/pull/6978) and [#7003](https://github.com/gfx-rs/wgpu/pull/7003).
|
||||
|
||||
- Added a hello window example. By @laycookie in [#6992](https://github.com/gfx-rs/wgpu/pull/6992).
|
||||
|
||||
|
||||
@@ -156,6 +156,12 @@ pub struct TextureBlitter {
|
||||
|
||||
impl TextureBlitter {
|
||||
/// Returns a [`TextureBlitter`] with default settings.
|
||||
///
|
||||
/// # Arguments
|
||||
/// - `device` - A [`Device`]
|
||||
/// - `format` - The [`TextureFormat`] of the texture that will be copied to. This has to have the `RENDER_TARGET` usage.
|
||||
///
|
||||
/// Properties of the blitting (such as the [`BlendState`]) can be customised by using [`TextureBlitterBuilder`] instead.
|
||||
pub fn new(device: &Device, format: TextureFormat) -> Self {
|
||||
TextureBlitterBuilder::new(device, format).build()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user