feat: export panel and Render menu, playback options, videos library (owner review 1 phase 5) (#27)
CI / Build and test (push) Successful in 9m41s
CI / Windows tests and installer (push) Skipped
CI / YAML check (push) Successful in 9s
Release / Build, test and publish (push) Successful in 14m49s
CI / PostgreSQL 16 integration (push) Successful in 8m51s
CI / PostgreSQL 17 integration (push) Successful in 9m48s
CI / Docker image (push) Successful in 54s
Release / Server image (push) Successful in 1m39s
CI / Build and test (push) Successful in 9m41s
CI / Windows tests and installer (push) Skipped
CI / YAML check (push) Successful in 9s
Release / Build, test and publish (push) Successful in 14m49s
CI / PostgreSQL 16 integration (push) Successful in 8m51s
CI / PostgreSQL 17 integration (push) Successful in 9m48s
CI / Docker image (push) Successful in 54s
Release / Server image (push) Successful in 1m39s
Owner review 1 R3, R8, R9. A grouped Export step and Render menu; encoding, playback (reverse, boomerang, loops, fades, hold) and still frames; one videos library on the desktop and the server with a verified trash and copies to a videos folder. Closes #21 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Alberto Balbo <alberto.balbo.96@gmail.com>
This commit was merged in pull request #27.
This commit is contained in:
1 parent
188b2c2e55
commit
728ffa35cb
729 files changed
+26954
-1652
No files matched your search
@@ -2,6 +2,7 @@ using Chronos.Core.Advice;
|
||||
using Chronos.Core.Diagnostics;
|
||||
using Chronos.Core.Export;
|
||||
using Chronos.Core.Imaging.Geometry;
|
||||
using Chronos.Core.Model;
|
||||
using Chronos.Core.Project;
|
||||
using Chronos.Core.Render;
|
||||
using Chronos.Core.Video;
|
||||
@@ -263,6 +264,34 @@ public sealed class EditorSession : IAsyncDisposable
|
||||
_ => [RenderRequest(export)],
|
||||
};
|
||||
|
||||
/// <summary>
|
||||
/// A source can save one frame as an image (owner review 1, R8, "Save frame"): a sequence of this PC or of a server, or a
|
||||
/// source that makes its own still jobs (<see cref="IProjectStills"/>, a workspace project). A source that renders
|
||||
/// elsewhere (<see cref="IProjectRenders"/>) without still jobs of its own saves none.
|
||||
/// </summary>
|
||||
public bool CanSaveFrames => Source is IProjectStills or not IProjectRenders;
|
||||
|
||||
/// <summary>
|
||||
/// The job that saves frame <paramref name="frameIndex"/> as one <paramref name="codec"/> image (one of
|
||||
/// <see cref="RenderRules.StillCodecs"/>) at the output size of <paramref name="export"/>, with every correction of the
|
||||
/// project as it is now and no playback (<see cref="ProcessingJobs.Still"/>): routed as <see cref="RenderRequests"/> is,
|
||||
/// on this PC's engine or on the server, as one job. The frame is named by its position and by its photo, whose hash
|
||||
/// wins when frames moved meanwhile. Null when the source saves no frames (<see cref="CanSaveFrames"/>).
|
||||
/// </summary>
|
||||
/// <exception cref="ArgumentOutOfRangeException"><paramref name="frameIndex"/> is not a frame of the sequence, or <paramref name="codec"/> is no still format.</exception>
|
||||
public IReadOnlyList<ArchiveJobRequest>? StillRequests(ExportSettings export, VideoCodec codec, int frameIndex)
|
||||
{
|
||||
ArgumentNullException.ThrowIfNull(export);
|
||||
ArgumentOutOfRangeException.ThrowIfGreaterThanOrEqual((uint)frameIndex, (uint)Content.Count, nameof(frameIndex));
|
||||
var photo = Content.Frames[frameIndex].Sha256;
|
||||
return Source switch
|
||||
{
|
||||
IProjectStills stills => stills.StillRequests(Content.Sequence, Project, export, codec, frameIndex, photo, Content.SourceWidth, Content.SourceHeight),
|
||||
IProjectRenders => null,
|
||||
_ => [ProcessingJobs.Still(Content.Sequence, export, codec, frameIndex, photo, Content.SourceWidth, Content.SourceHeight, Project with { Export = export })],
|
||||
};
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Makes a "Save both" copy of this PC's settings the project, as one undoable step; null when it stores the same values.
|
||||
/// </summary>
|
||||
@@ -608,6 +637,17 @@ public sealed class EditorSession : IAsyncDisposable
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// A source whose saved frames are made otherwise than from the project as the editor holds it (as <see cref="IProjectRenders"/>
|
||||
/// for renders): a workspace project would name the frame and its settings as its home reads them.
|
||||
/// </summary>
|
||||
public interface IProjectStills
|
||||
{
|
||||
/// <summary>The jobs that save frame <paramref name="frameIndex"/> (photo <paramref name="photoSha256"/>) of <paramref name="project"/> with <paramref name="export"/>.</summary>
|
||||
IReadOnlyList<ArchiveJobRequest> StillRequests(Sequence sequence, ProjectSettings project, ExportSettings export, VideoCodec codec, int frameIndex, string? photoSha256,
|
||||
int sourceWidth, int sourceHeight);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// A "Save both" copy made the project (<see cref="EditorSession.RestoreAsync"/>). Its Undo brings back the project from
|
||||
/// before as a new step, and only while the restore is still the last change: after another edit, an undo or a merged
|
||||
|
||||
Reference in new issue
Block a user