mirror of
https://github.com/horizon-rust/horizon.git
synced 2026-11-08 08:07:53 -10:00
Drop agent markers from code comments and the 0.2 prelude
PR-comment markers do not belong in source, and the 0.2 prelude text is part of every composed 0.2 stage. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
1 parent
67382d8ed2
commit
d4e13b4c08
6 files changed
+8
-8
No files matched your search
@@ -1172,7 +1172,7 @@ pub fn frame_inputs(
|
||||
let k = super::native_shadow::distortion(s.distance, s.resolution);
|
||||
2.0 * s.distance / s.resolution.max(1) as f32 * (1.0 - k)
|
||||
}),
|
||||
// 🤖 Agent: shader API 0.2's display fields, which 0.1 packs don't declare: SDR's values, also
|
||||
// Shader API 0.2's display fields, which 0.1 packs don't declare: SDR's values, also
|
||||
// with HDR on, until HDR output is served for 0.2 packs.
|
||||
hdr: 0,
|
||||
headroom: 1.0,
|
||||
|
||||
@@ -647,7 +647,7 @@ pub fn inspect(kind: &Kind, path: &Path) -> Result<Facts, String> {
|
||||
));
|
||||
}
|
||||
let m = pack.manifest;
|
||||
// 🤖 Agent: players get only what the game draws without a switch, and a line that may
|
||||
// Players get only what the game draws without a switch, and a line that may
|
||||
// still change in any release would break the packs listed for it.
|
||||
if m.api != horizon_shader_api::Api::V0_1 {
|
||||
return Err(format!(
|
||||
|
||||
@@ -362,7 +362,7 @@ mod tests {
|
||||
let wgsl = Frame::WGSL;
|
||||
assert_eq!(wgsl.fields.len(), 54);
|
||||
assert!(wgsl.fields.iter().all(|f| !f.doc.trim().is_empty()));
|
||||
// 🤖 Agent: 0.1's 49 fields, then 0.2's five and the padding to a multiple of 16.
|
||||
// 0.1's 49 fields, then 0.2's five and the padding to a multiple of 16.
|
||||
assert_eq!(
|
||||
std::mem::size_of::<Frame>(),
|
||||
6 * 64 + 15 * 16 + 8 * 16 + 2 * 16
|
||||
|
||||
@@ -108,7 +108,7 @@ pub fn markdown(api: Api) -> String {
|
||||
out += &table(kind.input(), None);
|
||||
if kind == StageKind::Material {
|
||||
let surface = table(&SURFACE, None);
|
||||
// 🤖 Agent: 0.2's lit colour is linear light and may pass white; 0.1's reference keeps its text.
|
||||
// 0.2's lit colour is linear light and may pass white; 0.1's reference keeps its text.
|
||||
out += &match api {
|
||||
Api::V0_1 => surface,
|
||||
Api::V0_2 => surface.replace(
|
||||
|
||||
@@ -132,7 +132,7 @@ const TONEMAP_RESOURCES: [Resource; 4] = [
|
||||
|
||||
/// 0.2's colour boundary, in every 0.2 prelude: vanilla's 2.2 power both ways.
|
||||
const COLOR_HELPERS: &str = "\
|
||||
// 🤖 Agent: Negatives and NaN made 0 (a comparison with NaN is false), so no `pow` sees them.
|
||||
// Negatives and NaN made 0 (a comparison with NaN is false), so no `pow` sees them.
|
||||
fn horizon_sanitize(c: vec3<f32>) -> vec3<f32> {
|
||||
return select(vec3<f32>(0.0), c, c > vec3<f32>(0.0));
|
||||
}
|
||||
@@ -142,7 +142,7 @@ fn horizon_decode(c: vec3<f32>) -> vec3<f32> {
|
||||
fn horizon_encode(c: vec3<f32>) -> vec3<f32> {
|
||||
return pow(horizon_sanitize(c), vec3<f32>(1.0 / 2.2));
|
||||
}
|
||||
// 🤖 Agent: Alpha is coverage: it stays as it is.
|
||||
// Alpha is coverage: it stays as it is.
|
||||
fn horizon_decode_rgba(c: vec4<f32>) -> vec4<f32> {
|
||||
return vec4<f32>(horizon_decode(c.rgb), c.a);
|
||||
}
|
||||
@@ -781,7 +781,7 @@ impl StageKind {
|
||||
(Api::V0_2, StageKind::Vertex) => VERTEX_ENTRIES_0_2,
|
||||
(Api::V0_2, StageKind::Weather) => WEATHER_ENTRIES_0_2,
|
||||
(Api::V0_2, StageKind::Post) => POST_ENTRIES_0_2,
|
||||
// 🤖 Agent: 0.1 has no tonemap stage: a manifest with one is refused before it is built.
|
||||
// 0.1 has no tonemap stage: a manifest with one is refused before it is built.
|
||||
(_, StageKind::Tonemap) => TONEMAP_ENTRIES,
|
||||
}
|
||||
}
|
||||
|
||||
@@ -137,7 +137,7 @@ fn the_frame_s_wgsl_layout_is_the_uploaded_struct_s() {
|
||||
let (wgsl, span) = frame_layout(Api::V0_2);
|
||||
assert_eq!(span, std::mem::size_of::<Frame>());
|
||||
assert_eq!(wgsl, rust);
|
||||
// 🤖 Agent: 0.1 declares the start of the same buffer.
|
||||
// 0.1 declares the start of the same buffer.
|
||||
let (wgsl, span) = frame_layout(Api::V0_1);
|
||||
assert_eq!(wgsl, rust[..Frame::FIELDS_0_1]);
|
||||
assert_eq!(span, rust[Frame::FIELDS_0_1].1);
|
||||
|
||||
Reference in new issue
Block a user