@@ -27,40 +27,13 @@ pub struct Camera3d {
2727 pub depth_load_op : Camera3dDepthLoadOp ,
2828 /// The texture usages for the depth texture created for the main 3d pass.
2929 pub depth_texture_usages : Camera3dDepthTextureUsage ,
30- /// How many individual steps should be performed in the `Transmissive3d` pass.
31- ///
32- /// Roughly corresponds to how many “layers of transparency” are rendered for screen space
33- /// specular transmissive objects. Each step requires making one additional
34- /// texture copy, so it's recommended to keep this number to a reasonably low value. Defaults to `1`.
35- ///
36- /// ### Notes
37- ///
38- /// - No copies will be performed if there are no transmissive materials currently being rendered,
39- /// regardless of this setting.
40- /// - Setting this to `0` disables the screen-space refraction effect entirely, and falls
41- /// back to refracting only the environment map light's texture.
42- /// - If set to more than `0`, any opaque [`clear_color`](Camera::clear_color) will obscure the environment
43- /// map light's texture, preventing it from being visible “through” transmissive materials. If you'd like
44- /// to still have the environment map show up in your refractions, you can set the clear color's alpha to `0.0`.
45- /// Keep in mind that depending on the platform and your window settings, this may cause the window to become
46- /// transparent.
47- pub screen_space_specular_transmission_steps : usize ,
48- /// The quality of the screen space specular transmission blur effect, applied to whatever's “behind” transmissive
49- /// objects when their `roughness` is greater than `0.0`.
50- ///
51- /// Higher qualities are more GPU-intensive.
52- ///
53- /// **Note:** You can get better-looking results at any quality level by enabling TAA. See: `TemporalAntiAliasPlugin`
54- pub screen_space_specular_transmission_quality : ScreenSpaceTransmissionQuality ,
5530}
5631
5732impl Default for Camera3d {
5833 fn default ( ) -> Self {
5934 Self {
6035 depth_load_op : Default :: default ( ) ,
6136 depth_texture_usages : TextureUsages :: RENDER_ATTACHMENT . into ( ) ,
62- screen_space_specular_transmission_steps : 1 ,
63- screen_space_specular_transmission_quality : Default :: default ( ) ,
6437 }
6538 }
6639}
@@ -107,33 +80,10 @@ impl From<Camera3dDepthLoadOp> for LoadOp<f32> {
10780 }
10881}
10982
110- /// The quality of the screen space transmission blur effect, applied to whatever's “behind” transmissive
111- /// objects when their `roughness` is greater than `0.0`.
112- ///
113- /// Higher qualities are more GPU-intensive.
114- ///
115- /// **Note:** You can get better-looking results at any quality level by enabling TAA. See: `TemporalAntiAliasPlugin`
116- #[ derive( Resource , Default , Clone , Copy , Reflect , PartialEq , PartialOrd , Debug ) ]
117- #[ reflect( Resource , Default , Clone , Debug , PartialEq ) ]
118- pub enum ScreenSpaceTransmissionQuality {
119- /// Best performance at the cost of quality. Suitable for lower end GPUs. (e.g. Mobile)
120- ///
121- /// `num_taps` = 4
122- Low ,
123-
124- /// A balanced option between quality and performance.
125- ///
126- /// `num_taps` = 8
127- #[ default]
128- Medium ,
129-
130- /// Better quality. Suitable for high end GPUs. (e.g. Desktop)
131- ///
132- /// `num_taps` = 16
133- High ,
134-
135- /// The highest quality, suitable for non-realtime rendering. (e.g. Pre-rendered cinematics and photo mode)
136- ///
137- /// `num_taps` = 32
138- Ultra ,
139- }
83+ /// If this component is added to a camera, the camera will use an intermediate "high dynamic range" render texture.
84+ /// This allows rendering with a wider range of lighting values. However, this does *not* affect
85+ /// whether the camera will render with hdr display output (which bevy does not support currently)
86+ /// and only affects the intermediate render texture.
87+ #[ derive( Component , Default , Copy , Clone , Reflect , PartialEq , Eq , Hash , Debug ) ]
88+ #[ reflect( Component , Default , PartialEq , Hash , Debug ) ]
89+ pub struct Hdr ;
0 commit comments