Normalize Comment Terminology

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
copeconeandClaude Sonnet 5.5 committed 2026-10-15 18:29:22 +09:00
1 parent 0fc01a84de
commit 961f78a332
25 files changed
+70 -70

No files matched your search

+1 -1
View File
@@ -39,7 +39,7 @@ public class RenderPreset
public static class PresetManager
{
/// <summary>
/// Built-in presets (H.264 CBR, 48 kHz stereo AAC at 256 kbps, mkv): 1080p, 1440p and 2160p at 60 fps video.
/// Built-in presets (H.264 CBR, 48 kHz stereo AAC at 256 kbps, mkv): 1080p, 1440p and 2160p at 60 FPS video.
/// "(4x)" presets render 240 game frames per second (4 per video frame); "(1x)" renders 60.
/// Video bitrates are in kbps.
/// </summary>
+14 -14
View File
@@ -92,7 +92,7 @@ internal static class RenderContext
}
};
/// <summary>
/// Called once on the main thread when the render finishes (success) or is cancelled or fails.
/// Called once on the main Unity thread when the render finishes (success) or is cancelled or fails.
/// A session callback replaces the default one, so no notification is shown when a session sets OnComplete.
/// Exceptions are caught and logged (RenderManager.TriggerOnComplete).
/// </summary>
@@ -101,7 +101,7 @@ internal static class RenderContext
private static readonly Action OnLastUpdateDefault = () => { };
/// <summary>
/// Called on the main thread every frame after all other LateUpdate calls, through PostRenderHook (attached when the
/// Called on the main Unity thread every frame after all other LateUpdate calls, through PostRenderHook (attached when the
/// game scene of the render has loaded) while the stage is Load or later.
/// Exceptions are caught and logged (RenderManager.TriggerOnLastUpdate).
/// </summary>
@@ -154,7 +154,7 @@ internal class RenderManager : MonoBehaviour
public static bool IsCapturingActive => Instance && Instance.stage >= RenderStage.Render;
/// <summary>
/// Maximum number of frames in ImageQueue. The main thread waits (throttles) while the queue holds more frames.
/// Maximum number of frames in ImageQueue. The main Unity thread waits (throttles) while the queue holds more frames.
/// </summary>
public const int MaxQueuedFrames = 64;
@@ -179,7 +179,7 @@ internal class RenderManager : MonoBehaviour
/// <summary>
/// Number of video frames sent to the encoder in this render. Incremented by the render thread (Interlocked),
/// read with Interlocked.Read by the main thread (result, debug monitor). Reset in SetupPlay.
/// read with Interlocked.Read by the main Unity thread (result, debug monitor). Reset in SetupPlay.
/// </summary>
public long framesSent;
@@ -276,14 +276,14 @@ internal class RenderManager : MonoBehaviour
/// <summary>
/// Configuration of the current render: a copy made by RenderSession.Start, so values adjusted during the render
/// (the audio sample rate in SetupPlay) do not change the caller's object. Read by the main thread, the render
/// (the audio sample rate in SetupPlay) do not change the caller's object. Read by the main Unity thread, the render
/// thread (audio settings) and the patches. Null until the first render starts.
/// </summary>
public RenderConfig Configuration = null!;
// Render Sessions State (OOP Instance Fields)
/// <summary>Current stage of the render. Written on the main thread; read by the render thread in TryDequeueNextFrame.</summary>
/// <summary>Current stage of the render. Written on the main Unity thread; read by the render thread in TryDequeueNextFrame.</summary>
public RenderStage stage = RenderStage.None;
/// <summary>Time.timeAsDouble when capture started. The time patch returns timeBase + frameCount / RenderFPS.</summary>
@@ -303,7 +303,7 @@ internal class RenderManager : MonoBehaviour
/// <summary>
/// Offline mixer of the song and sound effects of this render; null when audio is not rendered or no render runs.
/// Created in SetupPlay. Commands are added on the main thread (OnPostFrame, audio patches), mixing runs on the
/// Created in SetupPlay. Commands are added on the main Unity thread (OnPostFrame, audio patches), mixing runs on the
/// render thread (WriteAudioForFrame); the mixer synchronizes the two internally.
/// </summary>
public OfflineAudioMixer? AudioMixer { get; private set; }
@@ -392,10 +392,10 @@ internal class RenderManager : MonoBehaviour
public long lastVideoFrameIndex = -1;
/// <summary>
/// Video frame index of the last capture request (-1 before the first). Written on the main thread, read by the
/// Video frame index of the last capture request (-1 before the first). Written on the main Unity thread, read by the
/// render thread to know when every requested frame has been sent after endRequested.
/// </summary>
// long cannot be volatile: access via Volatile.Read/Write (written on main thread, read on render thread)
// long cannot be volatile: access via Volatile.Read/Write (written on main Unity thread, read on render thread)
public long lastRequestedVideoFrameIndex = -1;
/// <summary>
@@ -404,10 +404,10 @@ internal class RenderManager : MonoBehaviour
/// </summary>
public int readbackFailureCount;
/// <summary>Number of frames on which the main thread had to wait for the render thread (throttle loop entries).</summary>
/// <summary>Number of frames on which the main Unity thread had to wait for the render thread (throttle loop entries).</summary>
public int throttleCount;
/// <summary>True while the main thread is inside the throttle wait of OnPostFrame.</summary>
/// <summary>True while the main Unity thread is inside the throttle wait of OnPostFrame.</summary>
public bool isThrottling;
/// <summary>
@@ -438,7 +438,7 @@ internal class RenderManager : MonoBehaviour
/// <summary>
/// Captured frames waiting for the render thread, keyed by video frame index. Readbacks may complete in any order;
/// the render thread takes them in index order (passCount). Every access locks the list itself.
/// Frames are added by readback completions (main thread) and removed by the render thread, or released by the
/// Frames are added by readback completions (main Unity thread) and removed by the render thread, or released by the
/// cleanup in StopFFmpeg / RestoreRenderEnvironment.
/// </summary>
internal SortedList<long, CapturedFrame> ImageQueue = new();
@@ -788,7 +788,7 @@ internal class RenderManager : MonoBehaviour
if (!texture) return;
// [Backpressure Throttling]
// The main thread waits while ImageQueue holds more than QueueFrameLimit frames. Only the render thread
// The main Unity thread waits while ImageQueue holds more than QueueFrameLimit frames. Only the render thread
// removes frames, and it signals FrameDequeuedEvent for each one. The wait has a timeout so that the loop
// re-checks the render thread state and pumps pending readback completions (see ThrottleWaitMilliseconds).
isThrottling = false;
@@ -1249,7 +1249,7 @@ internal class RenderManager : MonoBehaviour
/// <summary>
/// Mixes the audio of the frame that was just sent (index passCount - 1) and writes it to the encoder.
/// The sample count per frame comes from SyncCalculator (sample rate / effective video FPS, with the remainder
/// carried to later frames). Mixing waits until the main thread has committed the audio commands up to that time.
/// carried to later frames). Mixing waits until the main Unity thread has committed the audio commands up to that time.
/// Does nothing when audio rendering is off. Render thread.
/// </summary>
/// <exception cref="OperationCanceledException">The mixer was cancelled (render aborted) while waiting.</exception>