問題タブ [tga]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
opengl-es - OpenGL テクスチャ フォーマットの制限
テクスチャも遵守する必要がある特定のフォーマット制限はありますか?
TGA ファイルを読み込んで、次のフラグメント シェーダーで描画しています。
16x16 の画像は問題なく表示されることがわかりました。64x16表示OK。72x16、80x16、96x16 は機能しません。
必要に応じて、TGA ファイルなどの詳細情報を提供します。
c++ - iostream を使用してパスにファイルを保存します
現在、lua と love2d で実装した 3D ソフトウェア レンダリングをいじっています。フォーラムの誰かが、さらに学ぶためにこのリンクを教えてくれました: C++ Software Renderer
これは C++ で書かれたソフトウェア レンダラーのチュートリアルで、追加のライブラリは使用されません。ですから、これは良いスタートになると思いました。
ただし、C、Objective-C、Swift、Java、およびLuaの経験はありますが、C++は初めてです。
まず、コマンド ライン C++ Xcode プロジェクトに 3 つのファイルをロードしました。
- main.cpp
- tgaimage.h
- tgaimage.cpp
アプリケーションをビルドして実行すると、User/Libraries/Developer/Xcode/projectname/Build/Products/Debug/output.tga にある .tga ファイルを取得することになっています。 User/Developer/Xcode Projects/tinyRenderer/ またはコードで実行できます。しかし、それはまさに私が行う方法がわかりません。
main.cpp で:
と呼ばれます。
tgaimage.h で:
そして実装ファイル:
ファイルを別のパスに保存するにはどうすればよいですか?
three.js - three.js: MTLLoader が tga テクスチャをロードしない
いくつかの.objファイルと対応する.mtlファイルのエクスポートがあります。テクスチャは.tga同じフォルダにフォーマットされています。
これが私のすべてをロードするために使用するコードです.obj:
車はロードされていますが、テクスチャはロードされていません。すべて白く表示され、コンソールにエラーはありません。追加してみました
しかし、何も変わりませんでした。
私も追加しようとしました
addCar関数を呼び出す前に。そうすると、コンソールに警告が表示されますが、テクスチャはまだ表示されません。

私が見たすべての例では、OBJLoader と MTLLoader を使用するとテクスチャが自動的にロードされますが、TGA テクスチャで OBJLoader と MTLLoader を使用する例はありませんでした。だから、それを機能させるために何かすることがあるのだろうかと思っています。
どんな助けでも大歓迎です。
PS: ファイル ( .obj、.mtlおよび.tga) は 3D max からエクスポートされます)。
c# - C# Load TGA and manipulate TGA image
I've been searching for an answer but cant get my head around this. I use C# alot but never actually dealt with graphics. I want to load a TGA image (32 bit) and then manipulate the color data ( including alpha channel ). How would a dumb dumb begin to approach this problem.
The basic manipulation I want to do is to change the coloring: The input is a mask image with 4 fixed colors (black, red, green, blue and alpha channel). I want to pull each channel and create a new image with certain colors instead of the original ones.
For example. Say I have a mask image with Black and Green and Alpha data. I want to make a new image with color1 where its black ( no channel is used ), color2 where its Green ( Only full green is used ) and color3 where its Alpha ( Only where alpha is used )
The input images don't have overlapping channels or alpha (A pixel has only one type of data, red, green, blue or alpha)
thanks in advance.