Video Watermark Advanced (高级水印)
A watermark that follows your subject
- video
- watermark_image
- video
- info
VideoWatermarkAdvanced is the plain VideoWatermark node with a tracking brain bolted on. Same text/logo stamping, same 22 animation effects, same local OpenCV pipeline - plus the ability to make the watermark chase a person through the frame, dodge busy areas, and process a whole folder of videos in one pass. If you're watermarking clips where the subject moves (which is most of them), a fixed corner stamp is easy to crop out; a watermark that rides along with the subject is a different problem for whoever wants to steal it. That's the pitch, and for the face/body case it mostly works.
How it works
Everything from the base watermark node applies, and on top of that:
- tracking_mode -
none,face,body, orobject. Here's the honest bit: face and body tracking are implemented with OpenCV's Haar cascades (the classichaarcascade_frontalface_default.xmlstyle classifiers that ship with opencv-python). They're fast and free, and they're also 2010-era tech - frontal faces track great, profile shots and heavily rotated subjects will lose the lock. Theobjectmode is a stub (aTODOin the source), so treat it as "not really implemented." Don't build your workflow on it. - tracking_position / tracking_offset_x / tracking_offset_y - place the watermark
above,below,left,right, oron_targetrelative to the detected target, with pixel offsets for fine placement (default offset -50 puts it above a face). - smooth_tracking / smoothing_factor - the node smooths the bounding box between frames so the watermark doesn't jitter; smaller factor = smoother, but laggier.
- enable_anti_occlusion / occlusion_detection_method - try to shift the watermark away from bright/edge/salient regions (
brightness,edge, orsaliencyscoring). Experimental, per the pack's own framing. - min_target_confidence - 0.1–1.0, default 0.5; raise it to require more confident detections (fewer false locks, more dropouts).
- batch_mode / batch_video_folder / batch_output_folder - process every video in a folder. Great for a day of generated clips; mind the disk space.
- text_effect -
noneorcurved, for arc-shaped text. It's the little flourish the basic node lacks.
Outputs: video (VIDEO) and info (STRING).
Install
Same pack install - ComfyUI Manager → "ComfyUI_Sora", or clone + pip install -r requirements.txt. No API key needed; Haar cascade files come bundled with opencv-python, so there's nothing extra to download.
Common issues
- Tracking loses the face mid-clip - expected with Haar cascades on side/rotated faces. Keep the subject front-facing, or fall back to fixed position for anything stylized.
- object mode does nothing - it's a stub; use face/body or the fixed multi-position presets instead.
- Watermark flickers between positions - that's
enable_multi_positionfightingtracking_mode; the tooltip even warns they conflict. Pick one. - Batch runs forever / fills the disk - batch mode re-encodes every video; check
batch_output_folderhas room and that you actually want all of them.
The honest verdict: for a fixed or animated watermark, the base node is plenty. Use this one when your clip has a clear frontal subject worth pinning a watermark to - it's a neat trick when it locks, and a "turn it off" when it doesn't.
Inputs (45)
| Name | Type | Default | Description |
|---|---|---|---|
| video | VIDEO | 输入视频(单个或批量) | |
| watermark_type | COMBO | text | 水印类型 |
| enable_watermark | BOOLEAN | true | — |
| tracking_modeopt | COMBO | none | 目标跟踪模式:none=固定位置, face=跟随人脸, body=跟随人体, object=跟随物体 |
| tracking_positionopt | COMBO | above | 水印相对目标的位置 |
| tracking_offset_xopt | INT | 0-500–500 | 跟踪时的X偏移 |
| tracking_offset_yopt | INT | -50-500–500 | 跟踪时的Y偏移 |
| enable_anti_occlusionopt | BOOLEAN | false | 自动调整位置避开重要内容 |
| occlusion_detection_methodopt | COMBO | brightness | 遮挡检测方法:brightness=亮度, edge=边缘, saliency=显著性 |
| min_target_confidenceopt | FLOAT | 0.500.1–1 | 目标检测最小置信度 |
| smooth_trackingopt | BOOLEAN | true | 使用平滑算法减少抖动 |
| smoothing_factoropt | FLOAT | 0.300.1–0.9 | 平滑系数(越小越平滑) |
| batch_modeopt | BOOLEAN | false | 是否批量处理多个视频 |
| batch_video_folderopt | STRING | 批量处理的视频文件夹路径 | |
| batch_output_folderopt | STRING | 批量输出文件夹路径 | |
| text_contentopt | STRING | © 2025 Your Brand | — |
| font_sizeopt | INT | 4812–200 | — |
| font_coloropt | COMBO | white | 9 options: white, black, red, green, blue, yellow, +3 |
| text_positionopt | COMBO | bottom_right | 10 options: top_left, top_center, top_right, center_left, center, center_right, +4 |
| text_opacityopt | FLOAT | 0.700–1 | — |
| watermark_imageopt | IMAGE | 水印图片 | |
| auto_remove_bgopt | BOOLEAN | false | 自动移除纯色背景(白底、黑底等) |
| bg_color_modeopt | COMBO | white | 背景颜色模式 |
| bg_thresholdopt | INT | 2400–255 | 背景检测阈值(越高越严格) |
| image_positionopt | COMBO | top_right | 10 options: top_left, top_center, top_right, center_left, center, center_right, +4 |
| image_scaleopt | FLOAT | 0.150.01–1 | — |
| image_opacityopt | FLOAT | 0.800–1 | — |
| combined_layoutopt | COMBO | text_below_image | 文字和图片组合布局(仅当watermark_type=both时生效) |
| combined_spacingopt | INT | 100–100 | 文字和图片之间的间距(像素) |
| text_effectopt | COMBO | none | 文字特效(curved=弧形文字) |
| margin_xopt | INT | 200–500 | — |
| margin_yopt | INT | 200–500 | — |
| animationopt | COMBO | none | 动画效果类型 - 新增10种吸引眼球的效果 |
| animation_durationopt | FLOAT | 2.00.1–30 | 动画持续时间(秒)- 数值越大动画越慢 |
| move_directionopt | COMBO | left_to_right | 4 options: left_to_right, right_to_left, top_to_bottom, bottom_to_top |
| rotation_speedopt | FLOAT | 301–360 | 旋转速度(度/秒)- 数值越小旋转越慢 |
| scale_range_minopt | FLOAT | 0.50.1–2 | — |
| scale_range_maxopt | FLOAT | 1.50.1–2 | — |
| blink_frequencyopt | FLOAT | 2.00.5–10 | — |
| enable_multi_positionopt | BOOLEAN | false | 水印在多个位置之间切换(与跟踪模式冲突) |
| multi_position_presetopt | COMBO | four_corners | 多位置预设方案 |
| position_listopt | STRING | top_left,top_right,bottom_left,bottom_right | 自定义位置列表(仅当preset=custom时使用) |
| position_switch_intervalopt | FLOAT | 3.00.5–30 | 位置切换间隔(秒) |
| add_shadowopt | BOOLEAN | true | — |
| shadow_offsetopt | INT | 20–10 | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| video | VIDEO | — |
| info | STRING | — |