Concept · Miller
The Miller for developers, projects' assets
With developer features on, the Miller finds your projects' asset folders and offers to shrink their images, videos and FLAC audio in place, losslessly or visually losslessly, keeping each file's name and format.
- Article
- 2303
- Applies to
- Miller 0.6.3
- Last reviewed
- For
- For developers
When it shows#
Only while Castellan's developer features are on: when a developer agent is hired. See Hiring, switching and letting staff go. Off, nothing of it is shown or run.
Which projects, and which folders#
Projects are Castellan's repositories, the ones Reeve lists, and any you add under Projects folders in Settings. When none of those gives one, Visual Studio's and GitHub Desktop's usual folders. Castellan's own agents' repositories are never offered.
Asset folders are those named assets, art, media, static, public, Content, Resources, res, sprites, audio, sounds, music, textures, images, img or video and the like, up to 6 levels down, plus any you add under More asset folders. Build output, dependencies, caches, dot-folders and submodules are never looked in.
What it does to each kind#
Each copy must be under 90% of the original's size, the same size in pixels, and the same format and extension.
| Files | How | Kept only when |
|---|---|---|
| PNG | Lossless: recompressed harder | The pixels are identical, and its palette, transparency and colour information are all still there. Animated PNGs are left alone. |
| JPEG | Visually lossless: re-encoded at very high quality | SSIM 0.99 or more against the original. Rotated, colour-profiled and CMYK JPEGs are left alone. |
| FLAC | Lossless: the highest compression | The samples are identical. Files with cover art are left alone. |
| MP4, M4V, MOV | Visually lossless: the same codec, at the Better preset, sound copied | The length, size and sound tracks match, and SSIM 0.98 or more. HDR, 10-bit or 4:4:4 video, subtitle tracks and videos over 30 minutes are left alone. |
May change a video's codec (off at first) lets a video become HEVC, still in its own MP4 or MOV. An extension never changes, since that would break the references to it. WAV, MP3, OGG, WebM, GIF and WebP aren't looked at: they can't be made smaller without changing format or losing quality again. A file the Miller replaced is never re-encoded again.
Measuring#
Every 15 minutes it measures up to 12 files, biggest first, at low priority, never while the hopper is grinding. Copies are made in the Miller's own folder, never in a project. The page shows, per project, what its files would save and what replacing them did save, and for each file what git says of it: not in git, committed, ignored, uncommitted changes, never committed, or unsure.
Replacing#
Tick files (or Tick all), and press Replace ticked. It asks first. Each one is replaced only if:
- it's still the file that was measured;
- git, asked again just then, says it's outside a repository, ignored, or committed with no changes.
A file with changes, never committed, or one git can't say about is never replaced. The original goes to the Recycle Bin, and the copy takes its name. In a repository, the change shows in git for you to commit, and the history keeps the old version.
Related articles
Is this page right?
If something on it is wrong or out of date, tell us and we'll fix the page.
Still stuck? Write to support@castellan-software.com and mention article 2303. Every version of Miller, and what changed in it, is in its release notes.