跳至主要內容

How to Edit a Specific Commit Message in Git

(the post is automatically translated by AI) Introduction When using Git [1] for version control, it’s easy to accidentally make a typo in a commit message — or simply realize later that it could be worded better. In those cases, you need to go back and fix the commit message. The basic approach is git commit --amend [2], which corrects the most recent commit message. In this article, I’ll document how to go back to an older commit — not just the last one — and edit its message for future reference. ...

May 29, 2022 · 2 min · GanniPiece

Why Coroutine? (Part 1) — Is Multithreading Not Enough?

(the post is automatically translated by AI) Introduction While working with UniVRM [1], I noticed that many Unity development scenarios rely on Coroutines — for example, opening a system file dialog or loading resources. In these situations, Coroutines are chosen to prevent background tasks from disrupting the user experience, such as when loading a large asset causes the window to freeze and the application becomes unresponsive. In this article, I’ll explain what a Coroutine is and compare it with Threads. I’ll then go into more detail about how Coroutines work and wrap up with a brief conclusion. If you’re interested in implementation, see the follow-up article: Why Coroutine? (Part 2) — Implementing a Coroutine in C. ...

May 28, 2022 · 4 min · GanniPiece

How to Enable and Detect Memory Leaks in the Unity Editor

(the post is automatically translated by AI) Introduction A memory leak occurs when allocated memory is never freed. While it doesn’t necessarily cause immediate crashes, a leak gradually reduces the available memory, degrading system performance over time. In severe cases, it can lead to unpredictable errors or even security vulnerabilities 1. Memory: “Hmm? Something smells.” One of the most common causes of memory leaks is forgetting to free dynamically allocated memory — for instance, calling new on the heap and never calling delete. The unpredictable timing of when this causes problems makes debugging quite difficult. ...

May 3, 2022 · 2 min · GanniPiece

How to Implement an XY Pad with JUCE

(the post is automatically translated by AI) Introduction The XY Pad is a common UI element in audio plugins — it lets you control two independent parameters at once. For example, you could set the X-axis to pan position and the Y-axis to volume level. Moving the thumb on the pad then simulates a sound source moving around the listener, which is a very intuitive control surface. A basic XY Pad consists of two parts: a Pad (the canvas) and a Thumb (the draggable indicator). Here’s an example from Cabbage Audio Forum: the white area is the Pad, the green circle is the Thumb. The Thumb’s position maps to the X and Y parameter values. ...

January 25, 2022 · 4 min · GanniPiece

How to Use git rebase to Integrate Branches

(the post is automatically translated by AI) Introduction With the plugin development mostly done, the next task is to merge two parallel branches of work. Git provides two approaches for this: merge and rebase. In this article, I’ll explain how rebase works and illustrate it with a practical example from our development workflow. How It Works git rebase replays commits from one branch on top of another, using the target branch as the new base. Suppose you have two branches A and B with diverging histories — you need to integrate their differences. ...

January 20, 2022 · 3 min · GanniPiece