tutorial 1 and 2
This commit is contained in:
@@ -22,10 +22,10 @@ class StaPipBagPackage {
|
||||
|
||||
StaPipBag* bag;
|
||||
|
||||
Vec4* vertices;
|
||||
Vec4* sts;
|
||||
Vec4* normals;
|
||||
Vec4* colors;
|
||||
const Vec4* vertices;
|
||||
const Vec4* sts;
|
||||
const Vec4* normals;
|
||||
const Vec4* colors;
|
||||
/** maxVertCount is max value, because we decided to put max maxVertCount
|
||||
* verts to single quad buffer in VU1 */
|
||||
u16 size;
|
||||
|
||||
@@ -23,10 +23,10 @@ class StaPipColorBag {
|
||||
~StaPipColorBag();
|
||||
|
||||
/** Optional. Single color for all vertices. */
|
||||
Color* single;
|
||||
const Color* single;
|
||||
|
||||
/** Optional. Color per vertex. */
|
||||
Color* many;
|
||||
const Color* many;
|
||||
};
|
||||
|
||||
} // namespace Tyra
|
||||
|
||||
@@ -45,28 +45,30 @@ class StaticPipeline : public Renderer3DPipeline {
|
||||
* Render static model
|
||||
* This render() method is a bridge to core.render() method.
|
||||
*/
|
||||
void render(StaticMesh* mesh, const StaPipOptions* options = nullptr);
|
||||
void render(const StaticMesh& mesh, const StaPipOptions* options = nullptr);
|
||||
void render(const StaticMesh* mesh, const StaPipOptions* options = nullptr);
|
||||
|
||||
private:
|
||||
RendererCore* rendererCore;
|
||||
Vec4* colorsCache;
|
||||
|
||||
void addVertices(MeshMaterialFrame* materialFrame, StaPipBag* bag) const;
|
||||
void addVertices(const MeshMaterialFrame* materialFrame,
|
||||
StaPipBag* bag) const;
|
||||
|
||||
StaPipInfoBag* getInfoBag(StaticMesh* mesh, const StaPipOptions* options,
|
||||
M4x4* model) const;
|
||||
StaPipInfoBag* getInfoBag(const StaticMesh* mesh,
|
||||
const StaPipOptions* options, M4x4* model) const;
|
||||
|
||||
StaPipColorBag* getColorBag(MeshMaterial* material,
|
||||
MeshMaterialFrame* materialFrame) const;
|
||||
StaPipColorBag* getColorBag(const MeshMaterial* material,
|
||||
const MeshMaterialFrame* materialFrame) const;
|
||||
|
||||
StaPipTextureBag* getTextureBag(MeshMaterial* material,
|
||||
MeshMaterialFrame* materialFrame);
|
||||
StaPipTextureBag* getTextureBag(const MeshMaterial* material,
|
||||
const MeshMaterialFrame* materialFrame);
|
||||
|
||||
StaPipLightingBag* getLightingBag(MeshMaterialFrame* materialFrame,
|
||||
StaPipLightingBag* getLightingBag(const MeshMaterialFrame* materialFrame,
|
||||
M4x4* model,
|
||||
const StaPipOptions* options) const;
|
||||
|
||||
void deallocDrawBags(StaPipBag* bag, MeshMaterial* material) const;
|
||||
void deallocDrawBags(StaPipBag* bag, const MeshMaterial* material) const;
|
||||
|
||||
void setLightingColorsCache(PipelineLightingOptions* lightingOptions);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user