Repository navigation
feat(backend): 壁纸视频单腿原生比例改版(画布跟随原图 + 条件 Aerial 微裁 + 尺寸护栏) - #6
Merged
Merged
Conversation
…裁 + 尺寸护栏) - 生成:单腿原生画布 computeNativeCanvas——EXIF 旋转后比例,32 取整 + 像素预算 1177600 + 短边 ≥704 + 比例 clamp [1,2.4];预裁仅比例对齐,去除人脸窗口重构图 - 转码:画廊原生 mp4 恒产出;Aerial 16:9 .mov 仅画布比例 ∈[1.5,1.9] 居中微裁产出, 窗口外 landscape 列留空 → mac 静态回退零改动 - 护栏:assertVideoDimensions 转码后断言尺寸,DimensionAssertError 传播为 job 失败 (rerun exit≠0),其余失败维持旁路当日回退静态;两转码+护栏全过才上传/写列 - 兼容:DB 新列 wallpaper_video_native_url + COS key _native.mp4 + manifest 字段 条件展开;portrait 列与历史两腿产物保留;画廊读取优先级 native > portrait > landscape - CLAUDE.md 同步新链路事实;backend 版本 0.11.0 → 0.12.0 Co-Authored-By: Claude Code <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
改动
壁纸视频生产从「固定横竖两腿」(横 1280×704 / 竖 736×1600)改为单腿原生比例:
computeNativeCanvas(origW, origH)(新增lib/wallpaper/native-canvas.ts):跟随 hero 原图 EXIF 旋转后比例,32 取整 + 像素预算 1,177,600 封顶 + 短边 ≥704 + 长短轴比 clamp [1, 2.4],朝向与长短轴解耦;7 组参考 fixture 全命中assertVideoDimensions转码后 ffprobe 断言;DimensionAssertError传播为 job 失败(rerun CLI exit≠0),其余失败维持旁路容错当日回退静态;两条转码+护栏全过才上传/写列wallpaper_video_native_url(纯增量);COS 新 key_native.mp4;manifest 新字段wallpaperVideoNative条件展开;画廊读取优先级 native > portrait > landscape;路由/企微推送零改动calculateMetadata参数化(props 携画布宽高);竖版顶部渐变压暗修复白字可读性(主仓库 overlay 工程已同步部署,原文件 .bak 备份)验证
worktree-env.acceptance环境基建项,与本 diff 零相关、改动前即失败)合并后(T6 生产三步)
node apps/gallery/scripts/deploy-gallery.mjs(画廊 native 优先级部署)DAILY_WALLPAPER_VIDEO=true npm run wallpaper-video:rerun -- --pickDate=<当日>抽查 + 次日 10:00 自然出片验收🤖 Generated with Claude Code