Spaces:
Running
Running
File size: 18,381 Bytes
4cbacf7 a7cb8f5 63e67b5 a7cb8f5 4cbacf7 a7cb8f5 4cbacf7 a7cb8f5 4cbacf7 a7cb8f5 4cbacf7 a7cb8f5 4cbacf7 a7cb8f5 4cbacf7 a7cb8f5 4cbacf7 a7cb8f5 4cbacf7 a7cb8f5 4cbacf7 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 |
<!DOCTYPE html>
<html lang="ko">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Veo3 ์์ ์ ์ ์คํ๋์ค</title>
<script src="https://cdn.tailwindcss.com"></script>
<script src="https://unpkg.com/lucide@latest/dist/umd/lucide.js"></script>
<script src="https://apis.google.com/js/api.js"></script>
<script>
API_KEY = "AIzaSyBt2gdFwXehWeYlcNetW89f5JHnQVXuhwI";
</script>
<style>
@keyframes float {
0%, 100% { transform: translateY(0px); }
50% { transform: translateY(-10px); }
}
@keyframes pulse-glow {
0%, 100% { box-shadow: 0 0 5px rgba(59, 130, 246, 0.5); }
50% { box-shadow: 0 0 20px rgba(59, 130, 246, 0.8); }
}
.float-animation {
animation: float 3s ease-in-out infinite;
}
.pulse-glow {
animation: pulse-glow 2s ease-in-out infinite;
}
.glass-effect {
background: rgba(255, 255, 255, 0.1);
backdrop-filter: blur(10px);
border: 1px solid rgba(255, 255, 255, 0.2);
}
.gradient-bg {
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}
.progress-bar {
transition: width 0.3s ease;
}
.drag-area {
border: 2px dashed rgba(59, 130, 246, 0.5);
transition: all 0.3s ease;
}
.drag-area:hover {
border-color: rgba(59, 130, 246, 1);
background: rgba(59, 130, 246, 0.05);
}
.drag-area.active {
border-color: #10b981;
background: rgba(16, 185, 129, 0.1);
}
.timeline-item {
transition: all 0.3s ease;
}
.timeline-item:hover {
transform: translateY(-2px);
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}
</style>
</head>
<body class="bg-gray-900 text-white min-h-screen">
<!-- ํค๋ -->
<header class="glass-effect p-4">
<div class="max-w-7xl mx-auto flex items-center justify-between">
<div class="flex items-center space-x-3">
<div class="w-10 h-10 bg-blue-500 rounded-lg flex items-center justify-center">
<i data-lucide="video" class="w-6 h-6"></i>
</div>
<h1 class="text-2xl font-bold">Veo3 ์์ ์ ์ ์คํ๋์ค</h1>
</div>
<div class="flex items-center space-x-4">
<button class="px-4 py-2 bg-blue-600 rounded-lg hover:bg-blue-700 transition">
<i data-lucide="save" class="w-4 h-4 inline mr-2"></i>์ ์ฅ
</button>
<button class="px-4 py-2 bg-green-600 rounded-lg hover:bg-green-700 transition">
<i data-lucide="play" class="w-4 h-4 inline mr-2"></i>๋ด๋ณด๋ด๊ธฐ
</button>
</div>
</div>
</header>
<!-- ๋ฉ์ธ ์ฝํ
์ธ -->
<main class="max-w-7xl mx-auto p-6 grid grid-cols-1 lg:grid-cols-3 gap-6">
<!-- ์ผ์ชฝ ํจ๋ - ํ๋ก์ ํธ ์ค์ -->
<div class="glass-effect rounded-xl p-6">
<h2 class="text-xl font-semibold mb-4 flex items-center">
<i data-lucide="settings" class="w-5 h-5 mr-2"></i>ํ๋ก์ ํธ ์ค์
</h2>
<div class="space-y-4">
<div>
<label class="block text-sm font-medium mb-2">ํ๋ก์ ํธ ์ด๋ฆ</label>
<input type="text" class="w-full px-3 py-2 bg-gray-800 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="๋์ ๋ฉ์ง ์์">
</div>
<div>
<label class="block text-sm font-medium mb-2">๋น๋์ค ์ ๋ชฉ</label>
<input type="text" class="w-full px-3 py-2 bg-gray-800 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="AI์ ๋๋ผ์ด ๋ฏธ๋">
</div>
<div>
<label class="block text-sm font-medium mb-2">์์ ์คํ์ผ</label>
<select class="w-full px-3 py-2 bg-gray-800 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500">
<option>์ํ์ (์๋ค๋งํฑ)</option>
<option>๋คํ๋ฉํฐ๋ฆฌ</option>
<option>๊ด๊ณ (๊ด๊ณ ํ๋ณด)</option>
<option>๊ต์ก(๊ฐ์ํ)</option>
<option>๋ธ์ด๋ก๊ทธ</option>
<option>๋ฆฌ๋ทฐ/์ธ๋ฐ์ฑ</option>
<option>๊ฒ์ ์คํธ๋ฆฌ๋ฐ</option>
<option>์
ํ ์ธํฐ๋ทฐ</option>
<option>๋ชจ์
๊ทธ๋ํฝ</option>
<option>3D ์ ๋๋ฉ์ด์
</option>
<option>2D ์นดํฐ/์ผ๋ฌ์คํธ</option>
<option>๋ธ๋๋ ํ๋ฆ</option>
<option>ํ๋ก๋ชจ์
๋ฎค์ง๋น๋์ค</option>
<option>์คํฑ๋ชจ์
</option>
<option>ํ์๋ฉ์ค/ํ์ดํผ๋ฉ์ค</option>
</select>
</div>
<div>
<label class="block text-sm font-medium mb-2">๊ธธ์ด (์ด)</label>
<input type="range" min="15" max="300" value="60" class="w-full">
<span class="text-sm text-gray-400">60์ด</span>
</div>
<div>
<label class="block text-sm font-medium mb-2">ํ์ง</label>
<select class="w-full px-3 py-2 bg-gray-800 rounded-lg">
<option>HD (720p)</option>
<option>FHD (1080p)</option>
<option>4K (2160p)</option>
</select>
</div>
</div>
</div>
<!-- ์ค์ ํจ๋ - ํ๋กฌํํธ ์
๋ ฅ -->
<div class="glass-effect rounded-xl p-6">
<h2 class="text-xl font-semibold mb-4 flex items-center">
<i data-lucide="edit-3" class="w-5 h-5 mr-2"></i>์์ ํ๋กฌํํธ
</h2>
<div class="space-y-4">
<div>
<label class="block text-sm font-medium mb-2">๋ฉ์ธ ํ๋กฌํํธ</label>
<textarea class="w-full px-3 py-2 bg-gray-800 rounded-lg h-32 resize-none focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="์: ๋ฏธ๋ ๋์์ ํ๋์์ ๋ด๋ ค๋ค๋ณด๋ ๋๋ก ๋ทฐ, ๋ค์จ ๋ถ๋น์ด ๋ฐ์ง์ด๋ ์ฌ์ด๋ฒํํฌ ์ธ๊ณ..."></textarea>
</div>
<div>
<label class="block text-sm font-medium mb-2">์ฅ๋ฉด ์ค๋ช
</label>
<textarea class="w-full px-3 py-2 bg-gray-800 rounded-lg h-24 resize-none focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="ํน์ ์ฅ๋ฉด์ด๋ ์์๋ฅผ ์ค๋ช
ํ์ธ์..."></textarea>
</div>
<div>
<label class="block text-sm font-medium mb-2">์์
์คํ์ผ</label>
<select class="w-full px-3 py-2 bg-gray-800 rounded-lg">
<option>์ํฝ ์ค์ผ์คํธ๋ผ</option>
<option>์๋ค๋งํฑ ํธ๋ ์ผ๋ฌ</option>
<option>๋กํ์ด ํํฉ</option>
<option>ํจ์ฒ ๋ฒ ์ด์ค</option>
<option>ํ์ฐ์ค/ํ
ํฌ๋
ธ</option>
<option>๋๋ผ์ค๋ฒ ์ด์ค</option>
<option>ํธ๋ฉ/EDM</option>
<option>์ฌ์ฆ ํผ์๋
ธ</option>
<option>์ด์ฟ ์คํฑ ํ</option>
<option>์ธ๋๋ก</option>
<option>๋ฐ๋ผ๋(๊ฐ์ฑ)</option>
<option>๊ตญ์
ํฌ๋ก์ค์ค๋ฒ</option>
<option>์ด๋ฆฐ์ด ๋์</option>
<option>์ฑ์
/ํด๋์</option>
<option>์นดํ ์ฌ์ฆ</option>
<option>๋ ํธ๋ก ์ ์ค์จ์ด๋ธ</option>
<option>8๋นํธ ๊ฒ์์์
</option>
<option>๋ด์์ด์ง ๋ช
์</option>
<option>ํํฌ/์์ธ</option>
<option>์๋๋ฎค์ง(์ํ๋ฆฌ์นด/๋ผํด)</option>
</select>
</div>
<button class="w-full py-3 bg-gradient-to-r from-purple-600 to-blue-600 rounded-lg hover:from-purple-700 hover:to-blue-700 transition font-semibold">
<i data-lucide="wand-2" class="w-5 h-5 inline mr-2"></i>AI๋ก ์์ ์์ฑํ๊ธฐ
</button>
</div>
</div>
<!-- ์ค๋ฅธ์ชฝ ํจ๋ - ๋ฏธ๋ฆฌ๋ณด๊ธฐ & ํ์๋ผ์ธ -->
<div class="glass-effect rounded-xl p-6">
<h2 class="text-xl font-semibold mb-4 flex items-center">
<i data-lucide="eye" class="w-5 h-5 mr-2"></i>๋ฏธ๋ฆฌ๋ณด๊ธฐ
</h2>
<!-- ๋น๋์ค ๋ฏธ๋ฆฌ๋ณด์ด -->
<div class="aspect-video bg-gray-800 rounded-lg mb-4 flex items-center justify-center relative">
<div class="absolute inset-0 bg-gradient-to-br from-purple-900/20 to-blue-900/20 rounded-lg"></div>
<div class="text-center z-10">
<i data-lucide="play-circle" class="w-16 h-16 mx-auto mb-2 text-gray-400"></i>
<p class="text-gray-400">๋ฏธ๋ฆฌ๋ณด๊ธฐ ์ค๋น์ค...</p>
</div>
</div>
<!-- ์งํ๋ฅ -->
<div class="mb-4">
<div class="flex justify-between text-sm mb-1">
<span>์์ฑ ์งํ๋ฅ </span>
<span id="progressText">0%</span>
</div>
<div class="w-full bg-gray-700 rounded-full h-2">
<div id="progressBar" class="bg-blue-500 h-2 rounded-full progress-bar" style="width: 0%"></div>
</div>
</div>
<!-- ํ์๋ผ์ธ -->
<div class="space-y-2">
<h3 class="text-sm font-medium">ํ์๋ผ์ธ</h3>
<div class="space-y-2 max-h-64 overflow-y-auto">
<div class="timeline-item bg-gray-800 rounded-lg p-3">
<div class="flex items-center justify-between">
<span class="text-sm">๋์์ ์๋ฒฝ ์ฅ๋ฉด</span>
<span class="text-xs text-gray-400">0-15์ด</span>
</div>
</div>
<div class="timeline-item bg-gray-800 rounded-lg p-3">
<div class="flex items-center justify-between">
<span class="text-sm">๋๋ก ์ด ๋ ์๊ฐ๋ ์ฅ๋ฉด</span>
<span class="text-xs text-gray-400">15-30์ด</span>
</div>
</div>
<div class="timeline-item bg-gray-800 rounded-lg p-3">
<div class="flex items-center justify-between">
<span class="text-sm">๋ค์จ ๋ถ๋น์ ๊ต์ฐจ๋ก</span>
<span class="text-xs text-gray-400">30-45์ด</span>
</div>
</div>
</div>
</div>
</div>
</main>
<!-- ํ๋จ ๋๋๊ทธ ์ค ๋๋กญ ์์ญ -->
<footer class="max-w-7xl mx-auto px-6 pb-6">
<div class="glass-effect rounded-xl p-6">
<h3 class="text-lg font-semibold mb-4 flex items-center">
<i data-lucide="upload-cloud" class="w-5 h-5 mr-2"></i>๋ฆฌ์์ค ์
๋ก๋
</h3>
<div class="drag-area rounded-lg p-8 text-center">
<i data-lucide="cloud-upload" class="w-12 h-12 mx-auto mb-3 text-gray-400"></i>
<p class="text-gray-400 mb-2">์ด๋ฏธ์ง, ๋น๋์ค, ์ค๋์ค ํ์ผ์ ๋๋๊ทธํ๊ฑฐ๋ ํด๋ฆญํ์ฌ ์
๋ก๋</p>
<p class="text-sm text-gray-500">์ง์ ํ์: JPG, PNG, MP4, MP3</p>
<input type="file" multiple class="hidden" id="fileInput" accept="image/*,video/*,audio/*">
</div>
</div>
</footer>
<!-- ๋ชจ๋ฌ -->
<div id="modal" class="fixed inset-0 bg-black bg-opacity-50 hidden items-center justify-center">
<div class="glass-effect rounded-xl p-6 max-w-md">
<h3 class="text-lg font-semibold mb-4">์์ฑ ์๋ฃ!</h3>
<p class="text-gray-400 mb-4">์์ ์์ฑ์ด ์๋ฃ๋์์ต๋๋ค. ๋ค์ด๋ก๋ํ์๊ฒ ์ต๋๊น?</p>
<div class="flex space-x-3">
<button class="flex-1 py-2 bg-blue-600 rounded-lg hover:bg-blue-700">๋ค์ด๋ก๋</button>
<button class="flex-1 py-2 bg-gray-700 rounded-lg hover:bg-gray-600" onclick="closeModal()">๋ซ๊ธฐ</button>
</div>
</div>
</div>
<script>
// Lucide ์์ด์ฝ ์ด๊ธฐํ
lucide.createIcons();
// ์ค์ ์งํ๋ฅ
let progress = 0;
const progressBar = document.getElementById('progressBar');
const progressText = document.getElementById('progressText');
// Veo API๋ก ์ค์ ์์ ์์ฑ
async function generateVideo(prompt) {
const requestBody = {
instances: [{
prompt: prompt
}],
parameters: {
aspectRatio: "16:9",
durationSeconds: 8
}
};
const res = await fetch(
`https://generativelanguage.googleapis.com/v1beta/videos:generate?key=${API_KEY}`,
{
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify(requestBody)
}
);
const data = await res.json();
return data.name; // operation name
}
async function getOperationStatus(name) {
const res = await fetch(
`https://generativelanguage.googleapis.com/v1beta/${name}?key=${API_KEY}`
);
return await res.json();
}
async function pollUntilDone(name) {
progress = 0;
const check = setInterval(async () => {
const op = await getOperationStatus(name);
const state = op.done ? 100 : Math.min(op.metadata?.video?.videoProgressPercent || progress + 5, 95);
progress = state;
progressBar.style.width = progress + '%';
progressText.textContent = Math.floor(progress) + '%';
if (op.done) {
clearInterval(check);
progressBar.style.width = '100%';
progressText.textContent = '100%';
const videoUri = op.response?.video?.videoUri;
if (videoUri) {
document.querySelector('.aspect-video').innerHTML =
`<video class="w-full h-full rounded-lg" controls src="${videoUri}"></video>`;
}
setTimeout(() => {
document.getElementById('modal').classList.remove('hidden');
document.getElementById('modal').classList.add('flex');
}, 500);
}
}, 2000);
}
async function handleGenerate() {
const prompt = document.querySelector('textarea').value.trim();
if (!prompt) {
alert('ํ๋กฌํํธ๋ฅผ ์
๋ ฅํ์ธ์!');
return;
}
try {
const operationName = await generateVideo(prompt);
await pollUntilDone(operationName);
} catch (e) {
alert('์์ ์์ฑ ์คํจ: ' + e.message);
}
}
// ๋๋๊ทธ ์ค ๋๋กญ
const dragArea = document.querySelector('.drag-area');
const fileInput = document.getElementById('fileInput');
dragArea.addEventListener('click', () => fileInput.click());
dragArea.addEventListener('dragover', (e) => {
e.preventDefault();
dragArea.classList.add('active');
});
dragArea.addEventListener('dragleave', () => {
dragArea.classList.remove('active');
});
dragArea.addEventListener('drop', (e) => {
e.preventDefault();
dragArea.classList.remove('active');
console.log('ํ์ผ ์
๋ก๋:', e.dataTransfer.files);
});
// AI ์์ฑ ๋ฒํผ ํด๋ฆญ
document.querySelector('button').addEventListener('click', handleGenerate);
// ๋ชจ๋ฌ ๋ซ๊ธฐ
function closeModal() {
document.getElementById('modal').classList.add('hidden');
document.getElementById('modal').classList.remove('flex');
}
// ๋ฐ์ํ ๋ฉ๋ด
const rangeInput = document.querySelector('input[type="range"]');
const rangeValue = document.querySelector('.text-sm.text-gray-400');
rangeInput.addEventListener('input', (e) => {
rangeValue.textContent = e.target.value + '์ด';
});
</script>
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - ๐งฌ <a href="https://enzostvs-deepsite.hf.space?remix=UltronBasecamp/veo3" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
</html> |