1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-06-20 16:41:33 +00:00

Start fixing landscape rendering for x86_64

Signed-off-by: Josua Grawitter <grewater@googlemail.com>

git-svn-id: https://openmw.svn.sourceforge.net/svnroot/openmw/trunk@131 ea6a568a-9f4f-0410-981a-c910a81bb256
This commit is contained in:
nkorslund 2009-08-28 19:18:42 +00:00
parent 00898117c7
commit 1b4dd5fd02
2 changed files with 8 additions and 7 deletions

View file

@ -108,6 +108,7 @@ struct AlphaInfo
static assert(AlphaInfo.sizeof == 6*4); static assert(AlphaInfo.sizeof == 6*4);
// Info about each submesh // Info about each submesh
// If you change this struct please check whether align(1) still fits.
align(1) align(1)
struct MeshInfo struct MeshInfo
{ {
@ -124,13 +125,13 @@ struct MeshInfo
// Size and offset of the vertex buffer // Size and offset of the vertex buffer
ulong vertBufSize, vertBufOffset; ulong vertBufSize, vertBufOffset;
// Texture name. Index to the string table.
int texName = -1;
// Number and offset of AlphaInfo blocks // Number and offset of AlphaInfo blocks
int alphaNum; int alphaNum;
ulong alphaOffset; ulong alphaOffset;
// Texture name. Index to the string table.
int texName = -1;
// Fill the given vertex buffer // Fill the given vertex buffer
void fillVertexBuffer(float vdest[]) void fillVertexBuffer(float vdest[])
{ {

View file

@ -63,13 +63,13 @@ struct MeshInfo
// Size and offset of the vertex buffer // Size and offset of the vertex buffer
int64_t vertBufSize, vertBufOffset; int64_t vertBufSize, vertBufOffset;
// Texture name. Index to the string table.
int32_t texName;
// Number and offset of AlphaInfo blocks // Number and offset of AlphaInfo blocks
int32_t alphaNum; int32_t alphaNum;
uint64_t alphaOffset; uint64_t alphaOffset;
// Texture name. Index to the string table.
int32_t texName;
inline void fillVertexBuffer(float *buffer, uint64_t size) const inline void fillVertexBuffer(float *buffer, uint64_t size) const
{ {
d_terr_fillVertexBuffer(this, buffer, size); d_terr_fillVertexBuffer(this, buffer, size);
@ -309,7 +309,7 @@ extern "C"
Ogre::Pass* np = mat->getTechnique(0)->getPass(0); Ogre::Pass* np = mat->getTechnique(0)->getPass(0);
np->setLightingEnabled(false); np->setLightingEnabled(false);
np->createTextureUnitState("_land_default.dds") np->createTextureUnitState("_land_default.dds")
->setTextureScale(scale,scale); ->setTextureScale(scale,scale);
} }
uint8_t *terr_makeAlphaLayer(const char* name, int32_t width) uint8_t *terr_makeAlphaLayer(const char* name, int32_t width)