update the logic to generate video on t2v

This commit is contained in:
2025-08-22 22:42:03 +02:00
parent 3a66ecc808
commit b04fc14a6f
2 changed files with 106 additions and 3 deletions

View File

@ -1,5 +1,6 @@
import { query } from './lib/mysql';
import { generateVideo } from './lib/video-generator';
//import { generateVideo } from './lib/video-generator';
import { generateVideo } from './lib/video-generator-text';
import { logger } from './lib/logger';
import dotenv from 'dotenv';
import path from 'path';
@ -80,8 +81,6 @@ async function worker(server: any) {
const videosToProcess = (await query(
`SELECT * FROM video
WHERE video_prompt IS NOT NULL
AND image_path IS NOT NULL
AND image_path != 'processing'
AND (video_path IS NULL OR video_path = '')
ORDER BY RAND() LIMIT 1`
)) as VideoRecord[];