Skip to content

Add p5.strands translations for shader examples and rename original GLSL examples#1238

Merged
ksen0 merged 4 commits intoprocessing:2.0from
MissTipo:shader-translation-glsl-to-p5-strands-2.0
Mar 20, 2026
Merged

Add p5.strands translations for shader examples and rename original GLSL examples#1238
ksen0 merged 4 commits intoprocessing:2.0from
MissTipo:shader-translation-glsl-to-p5-strands-2.0

Conversation

@MissTipo
Copy link
Contributor

Summary

This PR adds p5.strands translations for three existing shader examples and keeps the original GLSL versions alongside them for comparison.

Changes

  • renamed the original examples:
    • Filter Shader
    • Adjusting Positions With A Shader
    • Shader As A Texture
  • added p5.strands translations for each of the above examples
  • updated and remixed the example descriptions to match the renamed originals and the new p5.strands versions

Notes

The goal was to preserve the original GLSL examples while adding equivalent p5.strands versions that are easier to compare side by side.

Testing

  • ran the examples locally in the web editor/site preview
  • verified that the new p5.strands examples render correctly
  • verified that the original examples remain available under their renamed versions

- rename original GLSL examples to preserve them alongside the new versions
- add p5.strands translations for Filter Shader, Adjusting Positions With A Shader, and Shader As A Texture
- remix example descriptions to reflect the new p5.strands versions

Signed-off-by: MissTipo <dorine.a.tipo@gmail.com>
@ksen0 ksen0 self-requested a review March 16, 2026 13:31
Copy link
Collaborator

@davepagurek davepagurek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work converting these! This all works, so I just left some comments more about code style and using the most recent p5.strands features to simplify the code.

@MissTipo
Copy link
Contributor Author

Nice work converting these! This all works, so I just left some comments more about code style and using the most recent p5.strands features to simplify the code.

Thanks Dave! Making the changes. Will push updates soon.

…rect globals

- Switch filter shader to buildFilterShader + filterColor.begin/set/end
- Switch wiggle shader to buildColorShader + objectInputs.begin/end; drop time uniform
- Switch shader-as-texture to buildMaterialShader + cameraInputs/pixelInputs begin/end
- Remove unnecessary uniforms for millis/width/height/mouse and simplify numeric literals

Signed-off-by: MissTipo <dorine.a.tipo@gmail.com>
@MissTipo MissTipo requested a review from davepagurek March 18, 2026 09:41
@ksen0
Copy link
Member

ksen0 commented Mar 18, 2026

These look wonderful thank you @MissTipo !

Some minor notes added.

I was also inspecting how it looks on the website, and I propose that we add the 3 strands sketches to featured; and remove 3 of the previous sketches except "orbitControl." This would bring more visibility to the strands examples. Other ideas on how to make this more navigable is welcome @davepagurek (also @nbogie maybe you have thoughts?)

image image

For implement featured solution: add/remove featured: true from the description mdx of the affected sketches.

Finally, all past sketches do have translations. Minor/can be done in a separate PR but everywhere were the description text is the same, the existing translations can be duplicated for the strands sketch, I think.

Copy link
Member

@ksen0 ksen0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor

…ion support

- Feature the 3 new p5.strands example pages and unfeature 3 older sketches
- Fix GLSL title formatting ("Shader as a Texture (GLSL)")
- Update collectivelyAttributedSince to 2026 for the new translations
- Extend examples content schema to accept 2026 attribution year
- Add 2026 attribution string in UI copy (en)

Signed-off-by: MissTipo <dorine.a.tipo@gmail.com>
@MissTipo
Copy link
Contributor Author

Finally, all past sketches do have translations. Minor/can be done in a separate PR but everywhere were the description text is the same, the existing translations can be duplicated for the strands sketch, I think.

Happy to handle the translation copying too! A quick clarification on titles, should I append (p5.strands) to the title in each new strands translated file, and correspondingly append (GLSL) to the title in each existing translated file as with the English description or should everything stay as is?

@ksen0
Copy link
Member

ksen0 commented Mar 19, 2026

Thanks @MissTipo ! Yes please update the titles to include the (GLSL) and (p5.strands). Thank you!

cc @Divyansh013 for visibility - I think for GLSL and p5.strands those are technical terms and can stay in English but please let me know if there are any other ideas you have?

Copy link
Collaborator

@davepagurek davepagurek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code updates look great, nice work @MissTipo!

@ksen0 ksen0 self-requested a review March 20, 2026 23:00
@ksen0 ksen0 merged commit 3b93989 into processing:2.0 Mar 20, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants