Skip to content

Add bitmap layer studio usage examples#718

Open
222448082Ashen wants to merge 3 commits intothoth-tech:mainfrom
222448082Ashen:usageExamples/graphics-bitmap-layer-studio-1-example
Open

Add bitmap layer studio usage examples#718
222448082Ashen wants to merge 3 commits intothoth-tech:mainfrom
222448082Ashen:usageExamples/graphics-bitmap-layer-studio-1-example

Conversation

@222448082Ashen
Copy link
Copy Markdown

Description

This PR adds a new integrated Graphics usage example bundle for Bitmap Layer Studio across C++, C# (top-level + OOP), and Python, along with a PNG preview and a short title/description text file.

Motivation:

  • Provide a substantial multi-layer compositing example instead of a single-function snippet.
  • Demonstrate a consistent render pipeline and alpha-blend guide logic in all supported languages.
  • Improve category naming consistency in guides group metadata.

Related issue:

  • N/A (curriculum/task-driven addition).

Dependencies:

  • No new package dependencies were added.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation (update or new)

How Has This Been Tested?

Executed and verified:

  1. Usage example generation/validation:
    • node usage-examples-testing-script.cjs bitmap_layer_studio-1-example
  2. C++ compile in SplashKit MINGW64 environment:
    • ~/.splashkit/skm clang++ bitmap_layer_studio-1-example.cpp -o bitmap_layer_studio-1-example.exe
  3. Runtime launch smoke test (timed):
    • timeout 8s ./bitmap_layer_studio-1-example.exe

Notes:

  • Runtime warnings appear if expected layer image files are not present locally for execution.
  • Full docs build currently fails in this branch due to a pre-existing/generated duplicate import issue in usage-examples Animations output, not caused by Bitmap Layer Studio files.

Testing Checklist

  • Tested in latest Chrome
  • Tested in latest Firefox
  • npm run build
  • npm run preview

Checklist

If involving code

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings

If modified config files

  • I have checked package.json for changes
  • I have checked astro.config.mjs for changes
  • I have checked netlify.toml for changes
  • I have checked docker-compose.yml for changes
  • I have checked custom.css for changes

Folders and Files Added/Modified

  • Added:
    • bitmap_layer_studio-1-example.cpp
    • bitmap_layer_studio-1-example-top-level.cs
    • bitmap_layer_studio-1-example-oop.cs
    • bitmap_layer_studio-1-example.py
    • bitmap_layer_studio-1-example.png
    • bitmap_layer_studio-1-example.txt
  • Modified:
    • guides-groups.json

Additional Notes

  • The example logic and comments are aligned across C++, C#, and Python variants.
  • The example demonstrates strict back-to-front compositing plus alpha-guide calculations for teaching depth/layer ordering.

Add Bitmap Layer Studio usage examples in multiple languages: C# (OOP and top-level), C++, and Python, plus a PNG preview and short text blurb. Examples demonstrate loading four bitmap layers, alpha blending guides, and back-to-front compositing for parallax/depth. Also normalize category capitalization in scripts/json-files/guides-groups.json ("camera" -> "Camera", "graphics" -> "Graphics") for consistency.
@netlify
Copy link
Copy Markdown

netlify bot commented Apr 4, 2026

Deploy Preview for splashkit ready!

Name Link
🔨 Latest commit 34118b3
🔍 Latest deploy log https://app.netlify.com/projects/splashkit/deploys/69d088d11652320008c49e55
😎 Deploy Preview https://deploy-preview-718--splashkit.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Add API-aware URL resolution and expand usage example registry. Introduces getApiFunctionLookup and getExampleUrl in scripts/usage-example-scraping.cjs to decide whether an example should link to /api/... or /usage-examples/... based on api.json. Updates scripts/json-files/usage-example-references.json with new example entries (color, several geometry and graphics examples, a windows category, etc.), reorders/removes a duplicate lines_intersect entry, and adjusts example titles. These changes ensure example links point to the correct destination and register newly added examples.
Update usage example links to point at /api instead of /usage-examples and make the scraping/testing scripts more robust. Changes: adjusted JSON references to /api/, changed scraping fallback to return /api/<category>, simplified getFunctionLink to prefer unique_global_name anchors (stable API anchors), and added support for both nested and flat usage-example layouts by detecting folder structure and computing txt/code/output paths accordingly. These changes ensure links/anchors remain correct and examples are found for different repository layouts.
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.

1 participant