Update eval functions to deal with multi-output shaders

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

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

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
48/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
活発
技術スタック
cpp

調査の方向性

Start by locating the existing eval functions, vector sample function, and DEFINE_MAP_SHADER macro mentioned in the issue, then trace how they evaluate shaders and handle output buffers. Check how SceneClass exposes shader output counts and offsets. Done means both eval paths select multi-output sampling when the shader has multiple outputs and read the bound output at its offset, with a buffer-accepting vector sample function and a multi-output map shader macro.

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

説明

For the existing eval functions to work with multi-output shaders the eval functions need to recognize that it is a multi-output shader, pass a buffer which is large enough to receive all of the outputs, and pull the bound output from the appropriate offset. To determine if it is an multi-output shader you'll do a getShaderOutputCount() (or equivalent) on the SceneClass to see if it is more than 1. If it is more than 1 then the multi-output version of the sample function should be used and then the offset of the bound output can be retrieved using getShaderOutputOffset (or equivalent) on the SceneClass.

The vector sample function needs a version which passes a buffer as an argument rather than return the value and there needs to be a modified version of the DEFINE_MAP_SHADER macro which can be used for these multi-output shaders. Maybe this could be called DEFINE_MAP_SHADER_MULTIOUTPUT. As with the non-vector eval function the decision of which function to use depends on whether the shader being evaluated is multi-output.

主要言語
CMake
スター
4.7k
フォーク
321
平均マージ
13分
マージ済み PR(30日)
3

環境構築

はじめの一歩

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

OpenMoonRay/openmoonray のほかの issue

OpenMoonRay/openmoonray の issue をすべて見る

似ている issue

Computer Graphics の issue をもっと見る

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

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