3 lines
11 KiB
HTML
3 lines
11 KiB
HTML
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="API documentation for the Rust `bevy_image` crate."><title>bevy_image - Rust</title><script>if(window.location.protocol!=="file:")document.head.insertAdjacentHTML("beforeend","SourceSerif4-Regular-6b053e98.ttf.woff2,FiraSans-Regular-0fe48ade.woff2,FiraSans-Medium-e1aa3f0a.woff2,SourceCodePro-Regular-8badfe75.ttf.woff2,SourceCodePro-Semibold-aa29a496.ttf.woff2".split(",").map(f=>`<link rel="preload" as="font" type="font/woff2" crossorigin href="../static.files/${f}">`).join(""))</script><link rel="stylesheet" href="../static.files/normalize-9960930a.css"><link rel="stylesheet" href="../static.files/rustdoc-42caa33d.css"><meta name="rustdoc-vars" data-root-path="../" data-static-root-path="../static.files/" data-current-crate="bevy_image" data-themes="" data-resource-suffix="" data-rustdoc-version="1.84.0 (9fc6b4312 2025-01-07)" data-channel="1.84.0" data-search-js="search-92e6798f.js" data-settings-js="settings-0f613d39.js" ><script src="../static.files/storage-59e33391.js"></script><script defer src="../crates.js"></script><script defer src="../static.files/main-5f194d8c.js"></script><noscript><link rel="stylesheet" href="../static.files/noscript-893ab5e7.css"></noscript><link rel="alternate icon" type="image/png" href="../static.files/favicon-32x32-6580c154.png"><link rel="icon" type="image/svg+xml" href="../static.files/favicon-044be391.svg"></head><body class="rustdoc mod crate"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle" title="show sidebar"></button></nav><nav class="sidebar"><div class="sidebar-crate"><h2><a href="../bevy_image/index.html">bevy_<wbr>image</a><span class="version">0.15.1</span></h2></div><div class="sidebar-elems"><ul class="block"><li><a id="all-types" href="all.html">All Items</a></li></ul><section id="rustdoc-toc"><h3><a href="#modules">Crate Items</a></h3><ul class="block"><li><a href="#modules" title="Modules">Modules</a></li><li><a href="#structs" title="Structs">Structs</a></li><li><a href="#enums" title="Enums">Enums</a></li><li><a href="#constants" title="Constants">Constants</a></li><li><a href="#traits" title="Traits">Traits</a></li><li><a href="#functions" title="Functions">Functions</a></li></ul></section><div id="rustdoc-modnav"></div></div></nav><div class="sidebar-resizer"></div><main><div class="width-limiter"><rustdoc-search></rustdoc-search><section id="main-content" class="content"><div class="main-heading"><h1>Crate <span>bevy_image</span><button id="copy-path" title="Copy item path to clipboard">Copy item path</button></h1><rustdoc-toolbar></rustdoc-toolbar><span class="sub-heading"><a class="src" href="../src/bevy_image/lib.rs.html#2-38">Source</a> </span></div><h2 id="modules" class="section-header">Modules<a href="#modules" class="anchor">§</a></h2><ul class="item-table"><li><div class="item-name"><a class="mod" href="prelude/index.html" title="mod bevy_image::prelude">prelude</a></div></li></ul><h2 id="structs" class="section-header">Structs<a href="#structs" class="anchor">§</a></h2><ul class="item-table"><li><div class="item-name"><a class="struct" href="struct.CompressedImageFormats.html" title="struct bevy_image::CompressedImageFormats">Compressed<wbr>Image<wbr>Formats</a></div></li><li><div class="item-name"><a class="struct" href="struct.FileTextureError.html" title="struct bevy_image::FileTextureError">File<wbr>Texture<wbr>Error</a></div><div class="desc docblock-short">An error that occurs when loading a texture from a file.</div></li><li><div class="item-name"><a class="struct" href="struct.HdrTextureLoader.html" title="struct bevy_image::HdrTextureLoader">HdrTexture<wbr>Loader</a></div><div class="desc docblock-short">Loads HDR textures as Texture assets</div></li><li><div class="item-name"><a class="struct" href="struct.HdrTextureLoaderSettings.html" title="struct bevy_image::HdrTextureLoaderSettings">HdrTexture<wbr>Loader<wbr>Settings</a></div></li><li><div class="item-name"><a class="struct" href="struct.Image.html" title="struct bevy_image::Image">Image</a></div></li><li><div class="item-name"><a class="struct" href="struct.ImageLoader.html" title="struct bevy_image::ImageLoader">Image<wbr>Loader</a></div><div class="desc docblock-short">Loader for images that can be read by the <code>image</code> crate.</div></li><li><div class="item-name"><a class="struct" href="struct.ImageLoaderSettings.html" title="struct bevy_image::ImageLoaderSettings">Image<wbr>Loader<wbr>Settings</a></div></li><li><div class="item-name"><a class="struct" href="struct.ImageSamplerDescriptor.html" title="struct bevy_image::ImageSamplerDescriptor">Image<wbr>Sampler<wbr>Descriptor</a></div><div class="desc docblock-short">Indicates to an <code>ImageLoader</code> how an <a href="struct.Image.html" title="struct bevy_image::Image"><code>Image</code></a> should be sampled.</div></li></ul><h2 id="enums" class="section-header">Enums<a href="#enums" class="anchor">§</a></h2><ul class="item-table"><li><div class="item-name"><a class="enum" href="enum.DataFormat.html" title="enum bevy_image::DataFormat">Data<wbr>Format</a></div></li><li><div class="item-name"><a class="enum" href="enum.HdrTextureLoaderError.html" title="enum bevy_image::HdrTextureLoaderError">HdrTexture<wbr>Loader<wbr>Error</a></div></li><li><div class="item-name"><a class="enum" href="enum.ImageAddressMode.html" title="enum bevy_image::ImageAddressMode">Image<wbr>Address<wbr>Mode</a></div><div class="desc docblock-short">How edges should be handled in texture addressing.</div></li><li><div class="item-name"><a class="enum" href="enum.ImageCompareFunction.html" title="enum bevy_image::ImageCompareFunction">Image<wbr>Compare<wbr>Function</a></div><div class="desc docblock-short">Comparison function used for depth and stencil operations.</div></li><li><div class="item-name"><a class="enum" href="enum.ImageFilterMode.html" title="enum bevy_image::ImageFilterMode">Image<wbr>Filter<wbr>Mode</a></div><div class="desc docblock-short">Texel mixing mode when sampling between texels.</div></li><li><div class="item-name"><a class="enum" href="enum.ImageFormat.html" title="enum bevy_image::ImageFormat">Image<wbr>Format</a></div></li><li><div class="item-name"><a class="enum" href="enum.ImageFormatSetting.html" title="enum bevy_image::ImageFormatSetting">Image<wbr>Format<wbr>Setting</a></div></li><li><div class="item-name"><a class="enum" href="enum.ImageLoaderError.html" title="enum bevy_image::ImageLoaderError">Image<wbr>Loader<wbr>Error</a></div></li><li><div class="item-name"><a class="enum" href="enum.ImageSampler.html" title="enum bevy_image::ImageSampler">Image<wbr>Sampler</a></div><div class="desc docblock-short">Used in <a href="struct.Image.html" title="struct bevy_image::Image"><code>Image</code></a>, this determines what image sampler to use when rendering. The default setting,
|
|
<a href="enum.ImageSampler.html#variant.Default" title="variant bevy_image::ImageSampler::Default"><code>ImageSampler::Default</code></a>, will read the sampler from the <code>ImagePlugin</code> at setup.
|
|
Setting this to <a href="enum.ImageSampler.html#variant.Descriptor" title="variant bevy_image::ImageSampler::Descriptor"><code>ImageSampler::Descriptor</code></a> will override the global default descriptor for this <a href="struct.Image.html" title="struct bevy_image::Image"><code>Image</code></a>.</div></li><li><div class="item-name"><a class="enum" href="enum.ImageSamplerBorderColor.html" title="enum bevy_image::ImageSamplerBorderColor">Image<wbr>Sampler<wbr>Border<wbr>Color</a></div><div class="desc docblock-short">Color variation to use when the sampler addressing mode is <a href="enum.ImageAddressMode.html#variant.ClampToBorder" title="variant bevy_image::ImageAddressMode::ClampToBorder"><code>ImageAddressMode::ClampToBorder</code></a>.</div></li><li><div class="item-name"><a class="enum" href="enum.ImageType.html" title="enum bevy_image::ImageType">Image<wbr>Type</a></div><div class="desc docblock-short">The type of a raw image buffer.</div></li><li><div class="item-name"><a class="enum" href="enum.IntoDynamicImageError.html" title="enum bevy_image::IntoDynamicImageError">Into<wbr>Dynamic<wbr>Image<wbr>Error</a></div><div class="desc docblock-short">Errors that occur while converting an <a href="struct.Image.html" title="struct bevy_image::Image"><code>Image</code></a> into a <a href="../image/dynimage/enum.DynamicImage.html" title="enum image::dynimage::DynamicImage"><code>DynamicImage</code></a></div></li><li><div class="item-name"><a class="enum" href="enum.TextureAccessError.html" title="enum bevy_image::TextureAccessError">Texture<wbr>Access<wbr>Error</a></div><div class="desc docblock-short">An error that occurs when accessing specific pixels in a texture</div></li><li><div class="item-name"><a class="enum" href="enum.TextureError.html" title="enum bevy_image::TextureError">Texture<wbr>Error</a></div><div class="desc docblock-short">An error that occurs when loading a texture</div></li><li><div class="item-name"><a class="enum" href="enum.TranscodeFormat.html" title="enum bevy_image::TranscodeFormat">Transcode<wbr>Format</a></div></li></ul><h2 id="constants" class="section-header">Constants<a href="#constants" class="anchor">§</a></h2><ul class="item-table"><li><div class="item-name"><a class="constant" href="constant.SAMPLER_ASSET_INDEX.html" title="constant bevy_image::SAMPLER_ASSET_INDEX">SAMPLER_<wbr>ASSET_<wbr>INDEX</a></div></li><li><div class="item-name"><a class="constant" href="constant.TEXTURE_ASSET_INDEX.html" title="constant bevy_image::TEXTURE_ASSET_INDEX">TEXTURE_<wbr>ASSET_<wbr>INDEX</a></div></li></ul><h2 id="traits" class="section-header">Traits<a href="#traits" class="anchor">§</a></h2><ul class="item-table"><li><div class="item-name"><a class="trait" href="trait.BevyDefault.html" title="trait bevy_image::BevyDefault">Bevy<wbr>Default</a></div></li><li><div class="item-name"><a class="trait" href="trait.TextureFormatPixelInfo.html" title="trait bevy_image::TextureFormatPixelInfo">Texture<wbr>Format<wbr>Pixel<wbr>Info</a></div><div class="desc docblock-short">Extends the wgpu <a href="../wgpu_types/enum.TextureFormat.html" title="enum wgpu_types::TextureFormat"><code>TextureFormat</code></a> with information about the pixel.</div></li><li><div class="item-name"><a class="trait" href="trait.Volume.html" title="trait bevy_image::Volume">Volume</a></div><div class="desc docblock-short">Used to calculate the volume of an item.</div></li></ul><h2 id="functions" class="section-header">Functions<a href="#functions" class="anchor">§</a></h2><ul class="item-table"><li><div class="item-name"><a class="fn" href="fn.ktx2_buffer_to_image.html" title="fn bevy_image::ktx2_buffer_to_image">ktx2_<wbr>buffer_<wbr>to_<wbr>image</a></div></li><li><div class="item-name"><a class="fn" href="fn.ktx2_dfd_to_texture_format.html" title="fn bevy_image::ktx2_dfd_to_texture_format">ktx2_<wbr>dfd_<wbr>to_<wbr>texture_<wbr>format</a></div></li><li><div class="item-name"><a class="fn" href="fn.ktx2_format_to_texture_format.html" title="fn bevy_image::ktx2_format_to_texture_format">ktx2_<wbr>format_<wbr>to_<wbr>texture_<wbr>format</a></div></li><li><div class="item-name"><a class="fn" href="fn.ktx2_get_texture_format.html" title="fn bevy_image::ktx2_get_texture_format">ktx2_<wbr>get_<wbr>texture_<wbr>format</a></div></li></ul></section></div></main></body></html> |