I will list the files in the project to understand its current structure and dependencies.
I will read the package.json file to check the installed libraries and dependencies.
I will install necessary libraries: lucide-react, three, @types/three, canvas-confetti, @types/canvas-confetti, and jszip for icons, 3D WebGL diorama rendering, celebration effects, and ZIP exporting of layered collages.
I will update index.html to give the application a fitting title and description.
I will read index.html to see its current content.
I will now update index.html with the new title and Google Fonts.
I will read src/index.css to check the current styling setup.
I will update src/index.css to configure fonts, dark cyber-aesthetic color palettes, smooth scrollbars, and background glow utilities.
I will create src/types/index.ts to define data types for layers, depth maps, collage elements, 3D diorama camera settings, and user workspace states.
I will create src/data/presets.ts containing curated sample images across categories like Cyberpunk, Nature, Architecture, and Fantasy, along with sticker elements and geometric frames.
I will create src/utils/depthGenerator.ts to handle real-time depth map computation, spatial luminance analysis, and slicing RGB images into separated transparent PNG layers with feathering and edge enhancement.
I will create src/utils/exportUtils.ts to provide ZIP archiving of all separated layer PNGs, metadata JSON exporting, and stereoscopic Red-Cyan Anaglyph 3D image generation.
I will edit src/utils/exportUtils.ts to include sticker elements in the project metadata JSON and resolve the unused import lint error.
I will create src/components/Navbar.tsx for the main header, offering quick navigation between workspace modes and action triggers for gallery, collage elements, and exporting.
I will create src/components/SampleGalleryModal.tsx allowing users to choose from curated preset images with pre-configured depth maps or upload their own custom photos and depth maps.
I will create src/components/MixAndMatchModal.tsx to enable surreal "Mix & Match" chimera collages, allowing users to import specific depth layers from other presets (e.g., combining a Cyberpunk foreground character with an Elven Forest background).
I will remove the unused ArrowRight import from src/components/MixAndMatchModal.tsx.
I will create src/components/StickerLibraryModal.tsx providing decorative collage elements like cyber frames, retro badges, neon warning signs, and custom 3D floating text.
I will remove the unused imports from src/components/StickerLibraryModal.tsx.
I will create src/components/ExportModal.tsx offering export options: full transparent layered ZIP bundles, single composite PNGs, and Red-Cyan stereoscopic Anaglyph 3D images with celebration confetti.
I will remove the unused imports from src/components/ExportModal.tsx.
I will create src/components/workspace/ThreeDioramaView.tsx implementing the 3D Diorama and Parallax engine using Three.js, complete with orbital dollhouse perspectives, cinematic camera movements, mouse-follow parallax, and ambient particle effects.
I will update src/components/workspace/ThreeDioramaView.tsx to remove unused icon imports and implement Three.js Raycasting so users can click directly on layers in 3D space to select them for editing.
I will now add click-to-select raycasting in src/components/workspace/ThreeDioramaView.tsx so selectedLayerId and onSelectLayer are utilized.
I will check the cleanup return function in ThreeDioramaView.tsx to make sure the click event listener is properly removed on unmount.
I will read around line 330 to locate the useEffect cleanup function.
I will add window.removeEventListener('click', handleClick); to the cleanup function in ThreeDioramaView.tsx.
I will create src/components/workspace/TwoDCollageCanvas.tsx providing a full 2D collage editing workspace where users can drag, scale, rotate, flip, and apply blending effects to layers and stickers with visual selection bounding boxes.
I will edit src/components/workspace/TwoDCollageCanvas.tsx to fix the type checking on label vs name and integrate the visibility and locking toggle buttons directly into the floating active item inspector bar.
I will read around line 235 of TwoDCollageCanvas.tsx to inspect the active item toolbar.
I will read from line 310 to see the end of the quick transform bar.
I will edit TwoDCollageCanvas.tsx to fix the type checking on label/name and add visibility and locking toggle controls directly into the quick transform bar.
I will create src/components/workspace/DepthMapViewer.tsx providing an analytical dashboard where users can compare RGB images with their Depth Maps, adjust layer count thresholds, toggle near-far inversion, and enable paper-cutout edge styling.
I will remove the unused Sparkles import from src/components/workspace/DepthMapViewer.tsx.
I will create src/components/workspace/LayerBreakdownView.tsx displaying all sliced transparent layers in an interactive breakdown gallery with controls for blending modes, opacity, visibility, and standalone PNG exporting.
I will remove the unused CheckCircle2 import from src/components/workspace/LayerBreakdownView.tsx.
I will create src/components/HelpModal.tsx to provide users with a quick guide on 3D navigation, 2D collage dragging, and depth slicing controls.
I will remove the unused Sparkles import from src/components/HelpModal.tsx.
I will create src/App.tsx uniting the entire application: state management for layers and stickers, workspace mode switching, automated initial depth slicing of sample presets, and modal orchestrations.
I will edit src/App.tsx to remove the unused React import and fix the lint error.
I will now run build_project to test the build and ensure there are no compilation or TypeScript errors.
WEB上で深度(Depth)を用いて画像や写真を立体的にレイヤー分けし、3D空間や2Dキャンバスでコラージュ的な再構成を行う次世代クリエイティブプラットフォーム 「DepthCollage Studio (デプス・コラージュ・スタジオ)」 を作成しました!
🌟 アプリケーションの主な機能・特徴
1. 🚀 深度推定&画像スライシングエンジン (Depth Slicing & Separation)
- スマート深度自動推定: 写真やサンプル画像を読み込むだけで、画面内の空間周波数・輝度コントラスト・中心の立体配置をリアルタイム計算し、自動で美しい「グレースケール深度マップ(手前が白、奥が黒の階層グラデーション)」を生成します!
- 柔軟なレイヤー切り出し: 深度の閾値に基づいて、画像を 2〜10層(遠景・中景・近景・最前列など)の背景透過レイヤーとして自動スライスします。
- スマートエッジ処理&境界ぼかし (Feathering): 切り出しエッジのギザギザ(ジャギー)や背景の滲みを防ぐアルファグラデーション処理と背景色滲み除去機能を搭載しています。
2. 🌐 3D ジオラマ空間 & パララックスビュー (Three.js 3D Parallax Sandbox)
- 立体視差(パララックス・マウスフォロー): マウスを動かすと、各層のZ軸奥行きに応じた劇的な視差エフェクトを体験できます。
- 斜め・側面見取り図(オービットカメラ / Dollhouse View): 空間全体を斜め横から見下ろし、各層が「飛び出す絵本」や「舞台の書き割り」のように空間配置されている様子を観察できます。
- シネマティックカメラツアー & めまい効果 (Vertigo Zoom): ドリーズームやゆっくりとした空間周回による自動演出モード。
- 環境演出: 空間内に降る「星屑ダスト」「サイバーネオン雨」「金の火花」パーティクルや空間フォグ(霧)のON/OFFが可能です。
3. 🎨 2D コラージュ編集 & レイヤー加工ワークスペース
- 各レイヤーをマウスドラッグで自由に移動(X/Y軸)、サイズ拡大・縮小、回転、水平・垂直反転を適用できます。
- コラージュ・エフェクト: 各レイヤーの不透明度、色相・彩度・コントラスト、そして「乗算」「スクリーン」「オーバーレイ」などのブレンドモードを個別調整可能です。
- ✨ 切り絵風エフェクト (Paper Cutout Mode): 全レイヤーに白い縁取りと立体ドロップシャドウを施し、ペーパー・クラフトのようなアート感を付与できます。
- 🔄 深度の反転 (Invert Depth): 奥にある風景が最前面へと飛び出し、手前の人物が奥へと反転するシュールレアリズムな異次元構成を瞬時に作れます。
4. 🔀 ミックス&マッチ(キメラ合成)& 装飾シェイプライブラリ
- 異次元コラージュ(Mix & Match): 別のサンプル作品や写真から「背景(最遠景)」や「人物(最前列)」など特定の深度ゾーンだけをスライス抽出して現在の作品へインポート・合成できます!
- 3Dネオンテキスト&シェイプ装飾: 「背景と中景の間」や「人物の前面」など、深度空間(Z軸)の任意の中間層にネオンサイン、サイバーフレーム、カスタム立体テキストを挿入して挟み込むことができます。
5. 💾 クリエイター向けプロ仕様のエクスポート (Archive & 3D Export)
- 全レイヤーZIP一括保存: 分離された全ての透過PNGレイヤー画像、深度マップ、および各レイヤーのZ座標・エフェクト情報を記述したJSONメタデータを1つのZIPファイルに圧縮してダウンロードできます(After EffectsやPhotoshopでの映像・デザイン制作にそのまま活用可能!)。
- アナグリフ3D立体視画像: 左目(赤)と右目(シアン・青緑)の視差を計算した赤青アナグリフ画像を生成!赤青メガネをかけて見ると本物のように画面から飛び出す立体画像をお楽しみいただけます。
- 個別レイヤー展開図 (Layer Breakdown): 各層の一覧展示から、必要な透過PNGのみを単体ダウンロードすることも可能です。
Files built: index.html, src/index.css, src/types/index.ts, src/data/presets.ts, src/utils/depthGenerator.ts, src/utils/exportUtils.ts, src/components/Navbar.tsx, src/components/SampleGalleryModal.tsx, src/components/MixAndMatchModal.tsx, src/components/StickerLibraryModal.tsx, src/components/ExportModal.tsx, src/components/workspace/ThreeDioramaView.tsx, src/components/workspace/TwoDCollageCanvas.tsx, src/components/workspace/DepthMapViewer.tsx, src/components/workspace/LayerBreakdownView.tsx, src/components/HelpModal.tsx, src/App.tsx