Good default pattern for testing

This commit is contained in:
Peter Slattery 2022-08-09 17:08:35 -07:00
parent 2d3b4040e1
commit 2b29b3fa43
4 changed files with 16 additions and 2 deletions

Binary file not shown.

Binary file not shown.

View File

@ -1058,3 +1058,17 @@ pattern_felt_isolated_passive(Assembly_Pixel_Buffer pixels, Assembly_Strip_Array
} }
} }
void
pattern_rainbow(Assembly_Pixel_Buffer pixels, Assembly_Strip_Array strips, Incenter_State* ins)
{
Assembly_Pixel p = color_v3_to_assembly_pixel((v3){
.x = pm_sinf_01(ins->scene_time),
.y = pm_cosf_01(ins->scene_time),
.z = 0.5f,
});
for (u32 j = 0; j < pixels.len; j++)
{
pixels.pixels[j] = p;
}
}

View File

@ -53,8 +53,8 @@ incenter_scene_descs_init()
incenter_scene_descs[Incenter_Scene_WelcomeHome] = (Incenter_Scene){ incenter_scene_descs[Incenter_Scene_WelcomeHome] = (Incenter_Scene){
.name = "WelcomeHome", .name = "WelcomeHome",
.patterns = { .patterns = {
[Incenter_SceneMode_Intro] = pattern_sun_passive, [Incenter_SceneMode_Intro] = pattern_rainbow,
[Incenter_SceneMode_Passive] = pattern_sun_passive, [Incenter_SceneMode_Passive] = pattern_rainbow,
[Incenter_SceneMode_Input] = pattern_sun_passive, [Incenter_SceneMode_Input] = pattern_sun_passive,
}, },
}; };