Compare commits

..

2 Commits

Author SHA1 Message Date
5fd29ef5f3 use gmic instead of ai 2026-05-30 14:14:10 +02:00
cce988255b flip image 2026-05-30 14:13:51 +02:00
3 changed files with 6 additions and 18 deletions

View File

@ -19,9 +19,12 @@ class ConvertToComic implements ShouldQueue
public function handle(): void
{
$absolutePath = Storage::disk('public')->path($this->photoJob->image_path);
$script = base_path('convert_to_comic.sh');
$result = Process::timeout(0)->run('bash ' . escapeshellarg($script) . ' ' . escapeshellarg($absolutePath));
$result = Process::timeout(0)->run(
'gmic ' . escapeshellarg($absolutePath) .
' cl_comic 4,1,0,0,1,15,15,1,10,20,6,2,0,0,0,0,0,0,50,50' .
' -o ' . escapeshellarg($absolutePath)
);
$this->photoJob->update([
'status' => $result->successful() ? 'done' : 'failed',

View File

@ -1,15 +0,0 @@
#!/usr/bin/bash
export LANGUAGE=
source /home/alegab/workspace/comfy_ui/venv/bin/activate
cp "$1" /home/alegab/comfy/ComfyUI/input/fotobox.jpg
echo "input: $1" >> image_log.txt
output=$(comfy-cli run --workflow /home/alegab/comfy/ComfyUI/user/default/workflows/comic2.json | grep "Outputs" -A 2 | tail -n 2 | head -n 1 | strings)
output=$(tr -dc '[[:print:]]' <<< "$output" | cut -c 5-38,43-)
echo "output: $output" >> image_log.txt
cp $output "$1"

View File

@ -4,7 +4,7 @@
<div class="relative w-full max-w-2xl">
<video id="video" autoplay playsinline
class="w-full rounded-2xl shadow-2xl bg-gray-900 aspect-video object-cover"></video>
class="w-full rounded-2xl shadow-2xl bg-gray-900 aspect-video object-cover" style="transform: scaleX(-1);"></video>
<canvas id="canvas" class="hidden"></canvas>