MCPcopy Create free account
hub / github.com/doldecomp/mkdd / createModel

Method createModel

src/Kaneshige/GeoVision.cpp:90–111  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

88}
89
90void GeoVision::createModel(JKRSolidHeap *slid, u32 viewNo) {
91 J3DModelData *mdlData = mModel.getModelData();
92 J3DTexture *tex = mdlData->getTexture();
93 mImg = *tex->getResTIMG(0);
94
95 tex->setResTIMG(0, *getGeoVisionSupervisor()->getCaptureTexture()->getTexInfo());
96
97 int scrIdx = mdlData->getMaterialName()->getIndex(cChangeMaterialName);
98#line 282
99 JUT_ASSERT_MSG(scrIdx >= 0, "NOT FOUNT SCR MAT");
100
101 if (RaceMgr::getManager()->isMirror() && scrIdx >= 0) {
102 J3DMaterial *node = mdlData->getMaterialNodePointer(scrIdx);
103 J3DTexCoord *coord = node->getTexGenBlock()->getTexCoord(0);
104 coord->setTexGenMtx(30);
105 coord->setTexMtxReg(30);
106 J3DTexMtxInfo &mtxInfo = node->getTexMtx(0)->getTexMtxInfo();
107 mtxInfo.mSRT.mScaleX = -1.0f;
108 }
109
110 mModel.createDifferedModel(slid, viewNo, 0x4021200, false);
111}
112
113void GeoVision::calc() {
114 StateObserver::ExecuteState();

Callers

nothing calls this directly

Calls 15

setResTIMGMethod · 0.80
getTexInfoMethod · 0.80
getCaptureTextureMethod · 0.80
setTexMtxRegMethod · 0.80
createDifferedModelMethod · 0.80
getModelDataMethod · 0.45
getTextureMethod · 0.45
getResTIMGMethod · 0.45
getIndexMethod · 0.45
getMaterialNameMethod · 0.45
isMirrorMethod · 0.45

Tested by

no test coverage detected