- Introduced the `media_segment` tool to segment objects in video footage using SAM 2.1, allowing users to track objects and generate mask files.
- Implemented input validation for prompts, ensuring at least one point or a bounding box is provided for segmentation.
- Enhanced the output structure to include mask paths and tracking details, improving integration with the `<mask>` component in the editor.
- Added comprehensive documentation for the new tool, detailing usage, input parameters, and expected outputs.
- Updated related components and tests to support the new functionality, ensuring robust performance and user experience.
- Added new `ObjectMaskPanel` component to manage object masks within the effects inspector.
- Introduced functionality for adding and managing object masks, including dropdown menus for selecting masks and controls for editing.
- Enhanced the `EffectsInspector` to support object mask interactions, including displaying existing masks and allowing users to track new objects.
- Implemented brush functionality for painting masks directly onto video clips, improving user experience for object segmentation.
- Updated cursor styles for the object mask tool to provide clearer visual feedback during interactions.
- Refactored related components and utilities to support the new object mask features, ensuring seamless integration with existing functionality.
- Updated the `basename` function to trim trailing slashes from the input path, ensuring more accurate extraction of the base name.
- Enhanced the logic to handle both forward and backward slashes, improving compatibility across different operating systems.
- Introduced a new test suite in `projects.init.test.ts` to validate the behavior of the `initProject` function, ensuring it correctly initializes new projects and handles existing project directories.
- Refactored the `initProject` function in `projects.ts` to streamline project setup, including improved handling of entry files and package.json records.
- Enhanced error handling for invalid paths in the `initProject` function, ensuring only absolute paths are accepted.
- Updated the `scaffold` function to utilize the new `ensureRecord` function, improving code clarity and maintainability.
- Added tests for various scenarios, including creating new projects, preserving existing project data, and handling invalid inputs, to ensure robust project management functionality.
- Updated the file writing logic in `main.ts` to ensure that generated asset folders are properly marked to prevent unwanted reloads during writes.
- Introduced detailed logging for model call procedures in `trpc.ts`, capturing input arguments and execution time for better debugging and monitoring.
- Simplified logging in `gen-ai.ts` by removing unnecessary details from generation logs.
- Enhanced asset management in `library.ts` by adding functionality to handle partial assets and ensuring unique paths for stored assets.
- Updated the `Assets` component to include support for partial assets, allowing for better management of assets that are still generating.
- Introduced a new `PartialAssetItem` component to represent partial documents in the asset panel, providing options to retry or delete failed generations.
- Modified the `AssetInfoPanel` to display information about partial assets, including their status and error messages.
- Refactored the `useAssetSelection` hook to accommodate both assets and partial assets, improving the selection logic.
- Updated the `FolderItem` component to count partial assets alongside regular assets, enhancing folder statistics.
- Removed the `sourceErrorSystem` as part of the cleanup, streamlining error handling for asset generations.
- Added documentation updates to reflect changes in asset handling and the introduction of partial assets.
- Added a new channel `PROJECTS_FS_REAL_PATH` to resolve the real path of a given source, accommodating symbolic links.
- Updated the `listEntries` function to include a `link` property for entries that are symbolic links, improving asset management.
- Introduced the `realPathEntry` function to handle symlink resolution, ensuring accurate path retrieval.
- Enhanced the `removeEntry` function to prevent deletion of files outside the project directory, maintaining project integrity.
- Updated documentation to clarify symlink handling and the implications of linked assets in the project.
- Introduced `resultExtension` function to determine the appropriate file extension for generated assets based on MIME type and URL, improving file identification accuracy.
- Updated the `store` method in `EditorGenAi` to utilize the new extension logic, ensuring generated files are named correctly based on their content.
- Enhanced `detectMimeType` function to include image type sniffing, allowing for better handling of files without explicit extensions, thus improving overall asset processing reliability.
- Added comprehensive documentation for new functions to clarify their purpose and usage in the asset management workflow.
- Updated the peaks management system to streamline audio peak handling, including the removal of the `peaks-worker` and integration of waveform derivation directly in the asset cache.
- Enhanced the `derivePeaks` function to utilize the new `deriveWaveform` method, improving efficiency in generating audio peaks from media files.
- Refactored the `requestPeaks` and `getClipSamples` functions to accommodate changes in data structure, ensuring better performance and clarity in waveform rendering.
- Improved type definitions and documentation for better maintainability and understanding of the audio processing workflow.
- Added `@diffusionstudio/jsx` dependency to support JSX generation features.
- Integrated `assetSystem` into various components to streamline asset handling.
- Refactored `create-engine.ts`, `image-encoder.ts`, and `encoder.ts` to utilize the new asset management structure.
- Removed the obsolete `jsx-generation.ts` file, consolidating asset generation logic.
- Updated `library.ts` to improve asset resolution and management processes.
- Enhanced the `EditorPage` to incorporate AI generation capabilities, improving project workflows.
- Updated `AssetThumbnail` and `LazyAssetItem` components to improve layout and rendering performance by adjusting CSS classes.
- Refactored audio peak derivation to utilize a dedicated web worker, enhancing responsiveness by offloading processing from the main thread.
- Simplified the `derivePeaks` function to communicate with the new worker, improving code organization and maintainability.
- Added utility functions for managing TCP port listeners in the development environment, ensuring smoother server restarts.
- Introduced `AssetCache` to manage derived data such as thumbnails and audio peaks, stored under a new `cache/` directory.
- Implemented methods for deriving and retrieving thumbnails and audio peaks, enhancing performance by reducing redundant calculations.
- Updated asset management to utilize the cache, ensuring efficient access to derived data during rendering.
- Enhanced the `AssetThumbnail` component to support cached thumbnails, improving loading times and user experience.
- Refactored related components and systems to integrate caching functionality, streamlining asset handling across the application.
- Added support for asset manifests with read and write capabilities, allowing for better organization of project assets.
- Introduced new project channels for manifest reading and writing, enhancing communication between main and renderer processes.
- Improved file system interactions with new methods for listing, statting, and removing project files, streamlining asset management.
- Updated package dependencies to include `yaml` for manifest handling and linked `@diffusionstudio/assets` for asset management.
- Refactored existing code to integrate new asset handling features and improve overall project structure.