{"id":16271998,"url":"https://github.com/logcreative/beamerboost","last_synced_at":"2026-04-30T14:37:10.237Z","repository":{"id":168638042,"uuid":"482429117","full_name":"LogCreative/BeamerBoost","owner":"LogCreative","description":"Dirty-Frame and Parallel Rendering Implementation for LaTeX Beamer Preview","archived":false,"fork":false,"pushed_at":"2022-05-11T18:23:54.000Z","size":86,"stargazers_count":1,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-08T15:50:14.093Z","etag":null,"topics":["beamer","latex"],"latest_commit_sha":null,"homepage":"","language":"Lua","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lppl-1.3c","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LogCreative.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-04-17T04:49:29.000Z","updated_at":"2022-04-18T05:10:18.000Z","dependencies_parsed_at":null,"dependency_job_id":"5d093ad1-38b2-446e-ab82-abe2ebb86ec2","html_url":"https://github.com/LogCreative/BeamerBoost","commit_stats":null,"previous_names":["logcreative/beamerboost"],"tags_count":0,"template":true,"template_full_name":null,"purl":"pkg:github/LogCreative/BeamerBoost","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LogCreative%2FBeamerBoost","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LogCreative%2FBeamerBoost/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LogCreative%2FBeamerBoost/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LogCreative%2FBeamerBoost/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LogCreative","download_url":"https://codeload.github.com/LogCreative/BeamerBoost/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LogCreative%2FBeamerBoost/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32468009,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"ssl_error","status_checked_at":"2026-04-30T13:12:06.837Z","response_time":57,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["beamer","latex"],"created_at":"2024-10-10T18:15:44.521Z","updated_at":"2026-04-30T14:37:10.220Z","avatar_url":"https://github.com/LogCreative.png","language":"Lua","funding_links":[],"categories":[],"sub_categories":[],"readme":"# BeamerBoost\r\n\r\nLaTeX `beamer` 文档类的**脏帧渲染**与**并行渲染**的预览级实现，借助于 [`l3build`](https://github.com/latex3/l3build) (lua) 和 [PowerShell](https://docs.microsoft.com/powershell/) 实现。\r\n\r\n## 使用方法\r\n\r\n```shell\r\nl3build doc\r\n```\r\n以及可以使用 VS Code 预先配置的 `Recipe: preview`。\r\n\r\n为了使用并行渲染，请安装 PowerShell 7 并添加到路径（`pwsh` 在命令行中可以运行，以及需要允许脚本运行），否则将回退到非并行渲染。\r\n\r\n```shell\r\nl3build clean\r\n```\r\n将清理所有的临时文件。\r\n\r\n## 概览\r\n\r\n```mermaid\r\nflowchart TD\r\nE[Expand Input] --\u003e S[Split Frames] --\u003e P[Precompile Header] --\u003e D[Decide Dirty Frames]\r\nD --\u003e Frame0\r\nD --\u003e Frame3\r\nFrame0 --\u003e M[Merge Frames]\r\nFrame1 --\u003e M\r\nFrame2 --\u003e M\r\nFrame3 --\u003e M\r\nM --\u003e C[Clean Up]\r\n```\r\n\r\n\r\n## 测评\r\n\r\n在四逻辑核机器上测试。\r\n\r\n|| BeamerBoost | LaTeXmk | BeamerBoost 修改一帧 | LaTeXmk 修改一帧 |\r\n|---|---|---|---|---|\r\n|帧渲染完成时间(s)| 45 | | 8 | |\r\n|全部合成完成时间(s)| 57 | 16 | 14 | 14 |\r\n\r\n从该表可以看出，使用 BeamerBoost 不能够减少初始化时间（甚至成倍的增长了），但是通过脏区渲染，可以较早地拿到所有帧的数据，虽然最后的合并阶段仍然同样依赖于 I/O 的速度，但对于构建一些实用软件而言，每次渲染预览少了几秒，按照每个文件可能会构建 100 次计算，将会减少 10 分钟的构建时间。\r\n\r\n| | BeamerBoost (每帧渲染两次) | BeamerBoost (每帧渲染两次) 修改一帧 |\r\n|---|---|---|\r\n|帧渲染完成时间(s)| 80 | 10 |\r\n|全部合成完成时间(s)| 93 | 16 |\r\n\r\n在 `build.lua` 文件中可以更改 `secondpass` 参数用于编译两次之用，用于编译目录等用途。该表依然显示如果不进行合并，时间仍然会有节省。并行渲染对于大型多核服务器可以更好地发挥其效能，这种拆分工作的方式也可以用于分布式计算。\r\n\r\n## 目前缺陷\r\n\r\n- `allowframebreak` 可能会导致页码错误（无法预估）\r\n- 仅支持 `pdflatex`，因为 `xelatex` 和 `lualatex` 的 OpenType 字体载入无法通过 `mylatexformat` 缓存，但是愿景依然是在预览完毕后，再通过较慢的方式渲染一遍。为了获得全平台中文支持（Linux 或 Mac），你可能需要使用 `CJK` 手动方法。（事实上 `xelatex` 在类 Unix 平台上的速度要比 Windows 上快得多，可以不需要再用这种并行渲染的方式。）\r\n```latex\r\n\\documentclass{beamer}\r\n\\usepackage{CJKutf8}\r\n\\begin{document}\r\n\\begin{CJK}{UTF8}{gbsn}\r\n中文内容\r\n\\end{CJK}\r\n\\end{document}\r\n```\r\n- 需要工整的代码，也就是一行只有一个命令。\r\n- 太过复杂的代码可能无法解析，请保证代码能够用正常的编译方式正常通过。\r\n- 文档类中预置的 `\\AtBeginPart`, `\\AtBeginSection`, `\\AtBeginSubsection`, `\\AtBeginSubsubsection` 命令将会被全部清空，请显式地在主文件添加相关命令，并且不区分是否带星号的版本（可选参数无效），这类命令的最后一个大括号必须单独占一行。\r\n\r\n## 相关项目\r\n\r\n[AutoBeamer](https://github.com/LogCreative/AutoBeamer) 用于转换 Markdown 为 beamer 代码。\r\n\r\n[ReportBoost](https://github.com/LogCreative/ReportBoost) 用于准备一个开箱即用的预编译环境。\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flogcreative%2Fbeamerboost","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flogcreative%2Fbeamerboost","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flogcreative%2Fbeamerboost/lists"}