Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

(RFC) deprecate `scale` etc.

オープン
#3,164 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 2 日以内に返信

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
62/100
issue の種類
リファクタリング
明瞭さ
おおむね明確
活発さ
活発
技術スタック
typescript

調査の方向性

Start by locating the definitions of std.scale4, std.rotate4/rotate3 and std.translate4 in the typegpu package (search for gpuScaling4 and the std export surface), plus their tests and docs pages. Read the single existing comment to see whether the maintainer has settled on plain deprecation vs. removal, then add @deprecated JSDoc pointing users at d.mat4x4f.scaling/rotation/translation with explicit matrix multiplication. Done means the functions still work, every call site in docs/examples that used them is updated, and the test suite passes.

索引モデルが issue の本文から書いたものです。

説明

stability

We support both d.mat4x4f.scaling, which returns a scaling matrix, as well as std.scale, which takes in a matrix and scales it.
The issue I see is that std.scale imposes a convention, it multiplies by the scaling matrix from the left: (${gpuScaling4(ctx, [vector])} * ${matrix}).
This may be unintuitive when applying some transformations manually, especially since wgpu-matrix uses the opposite order.

import { tgpu, d, std } from 'typegpu';
import * as m from 'wgpu-matrix';

const mat = d.mat4x4f(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16);
console.log(std.scale4(mat, d.vec3f(1, 2, 3)));
console.log(m.mat4.scale(mat, d.vec3f(1, 2, 3))); // different from previous log

I'd suggest we deprecate scale4, rotate?4 and translate4.
People can multiply scaling/rotation/translation matrices themself insead.

主要言語
TypeScript
スター
3.3k
フォーク
135
平均マージ
4日 1時間
マージ済み PR(30日)
64

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

software-mansion/TypeGPU のほかの issue

software-mansion/TypeGPU の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。