@typegpu/gl: support texture.write() options
メンテナーはふだん 2 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 47/100
- issue の種類
- 機能追加
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- typescript
- 領域
- backend
調査の方向性
Start in packages/typegpu-gl at WebGLTexture.write() and compare its behavior with the WebGPU texture write path, especially the handling of 'render' textures. The issue lists WebGL 2 mappings for several options and calls out framebuffer blitting for resampling; identify which options can be supported and which need a specific error. Done means options work where supported and unsupported ones are named in the error; the issue does not name tests to run.
索引モデルが issue の本文から書いたものです。
説明
Description
On a root from @typegpu/gl, any texture.write() call that passes an options object throws:
WebGL fallback does not support texture.write() options yet.
Code that passes options on WebGPU, such as { premultipliedAlpha: false, fit: 'clip' } (added in #2641), has to check isGLRoot(root) and call write differently on each backend:
if (isGLRoot(root)) {
texture.write(source);
} else {
texture.write(source, { premultipliedAlpha: false, fit: 'clip' });
}
This defeats the point of a drop-in fallback.
Proposal
Support the options in WebGLTexture.write() in packages/typegpu-gl, or at least accept and ignore those that already match WebGL's behavior. Most of them map onto WebGL 2 directly:
premultipliedAlpha:UNPACK_PREMULTIPLY_ALPHA_WEBGLflipY:UNPACK_FLIP_Y_WEBGLorigin/mipLevel: thexoffset/yoffset/levelarguments oftexSubImage2DsourceOriginandfit: 'clip':UNPACK_SKIP_PIXELS/UNPACK_SKIP_ROWS/UNPACK_ROW_LENGTHfor buffers, or a sizedtexSubImage2Dfor image sourcesfit: 'fill'/ resampling: a blit through a framebuffer, as the WebGPU path does for 'render' textures
Options that can't be supported should throw a specific error naming the unsupported option rather than rejecting every options object.
Found in @typegpu/gl 0.12.6. Related: #2641, #2858, #1637.
- 主要言語
- TypeScript
- スター
- 3.3k
- フォーク
- 135
- 平均マージ
- 4日 1時間
- マージ済み PR(30日)
- 64
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
software-mansion/TypeGPU のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
software-mansion/TypeGPU#3219 · コメント 1 件 ·
メンテナーはふだん 2 日以内に返信
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
software-mansion/TypeGPU#3213 · コメント 1 件 ·
メンテナーはふだん 2 日以内に返信
-
enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
software-mansion/TypeGPU#3008 · コメント 1 件 ·
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
software-mansion/TypeGPU#2948 · コメント 2 件 ·
メンテナーはふだん 2 日以内に返信
-
docs: Fix camera orientation in "Monocular Light Injection" example対応中かも @pullfrog が 60 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
software-mansion/TypeGPU#2890 · コメント 1 件 ·
メンテナーはふだん 2 日以内に返信
software-mansion/TypeGPU の issue をすべて見る
似ている issue
-
docs(api): openapi.yaml still documents gif-tools optimize colors as 2-256 instead of 2, 4, 16, 256オープンarea: backend documentation priority: low
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
snapotter-hq/SnapOtter#2919 ·
メンテナーはふだん 1 日以内に返信
-
accepted :+1: bug db/redis
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
beekeeper-studio/beekeeper-studio#4882 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
ready-for-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
konflux-ci/konflux-ui#1630 · コメント 1 件 ·
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 67/100
ahmedkhaleel2004/gitdiagram#233 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
simkimsia/netlify-axi#19 ·
メンテナーはふだん 1 日以内に返信