Merged revisions 1357:1366 from 1.4 branch.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@1367 dfc29bdd-3216-0410-991c-e03cc46cb475
master
hybrid 2008-06-12 11:15:45 +00:00
parent 96b3d0beed
commit c55da82a0c
12 changed files with 28 additions and 27 deletions

View File

@ -53,7 +53,7 @@ Changes in version 1.5 (... 2008)
- Finally added StarSonata patch with table element and TabControl additions. Table is based on MultiColor listbox by Acki, and has loads of changes by CuteAlien.
-------------------------------------------
Changes in version 1.4.1 (??.5.2008)
Changes in version 1.4.1 (04 Jun 2008)
- MD3 meshes are movable again.
@ -141,7 +141,7 @@ Changes in version 1.4.1 (??.5.2008)
- Bugfix getCurrentRenderTargetSize in D3D drivers. Due to signature differences a wrong virtual method was chosen. Thanks to Jiang for finding it.
-------------------------------------------
Changes in version 1.4 (30.11.2007)
Changes in version 1.4 (30 Nov 2007)
- Major API change: All material properties which are available per texture layer (curently texture, texture matrix, texture filters, and texture wrap mode) are separated into a new struct SMaterialLayer. You can access them via the array TextureLayer[] in SMaterial. The texture matrix methods in SMaterial are still alive, and also textures can be accessed via methods in SMaterial now. But still, many places in user code need some update (usually changing material.Textures[i] to material.TextureLayer[i].Texture etc.)

View File

@ -736,7 +736,7 @@ void CDemo::createParticleImpacts()
if (sound)
{
// adjust max value a bit to make to sound of an impact louder
sound->setMinDistance(200);
sound->setMinDistance(400);
sound->drop();
}
}

View File

@ -69,7 +69,7 @@ private:
CMainMenu::CMainMenu()
: startButton(0), device(0), selected(2), start(false), fullscreen(true),
music(true), shadows(false), additive(false), transparent(true), vsync(true)
music(true), shadows(false), additive(false), transparent(true), vsync(false)
{
}

View File

@ -324,11 +324,11 @@ namespace video
\param vertices Pointer to array of vertices.
\param vertexCount Amount of vertices in the array.
\param indexList Pointer to array of indices.
\param triangleCount Amount of Triangles.
\param primCount Amount of Primitives
\param vType Vertex type, e.g. EVT_STANDARD for S3DVertex.
\param pType Primitive type, e.g. EPT_TRIANGLE_FAN for a triangle fan. */
virtual void drawVertexPrimitiveList(const void* vertices, u32 vertexCount,
const u16* indexList, u32 triangleCount,
const u16* indexList, u32 primCount,
E_VERTEX_TYPE vType, scene::E_PRIMITIVE_TYPE pType) = 0;
//! Draws an indexed triangle list.

View File

@ -277,16 +277,12 @@ bool CGUIComboBox::OnEvent(const SEvent& event)
core::position2d<s32> p(event.MouseInput.X, event.MouseInput.Y);
// send to list box
if (ListBox && ListBox->getAbsolutePosition().isPointInside(p) &&
ListBox->OnEvent(event))
return true;
else
{
if (!(ListBox &&
ListBox->getAbsolutePosition().isPointInside(p) &&
ListBox->OnEvent(event)))
openCloseMenu();
return true;
}
return true;
}
break;
case EMIE_MOUSE_WHEEL:
{
s32 oldSelected = Selected;

View File

@ -816,7 +816,7 @@ bool CIrrDeviceLinux::run()
SKeyMap mp;
//mp.X11Key = XLookupKeysym(&event.xkey, 0);
char buf[5]="\0\0\0\0";
XLookupString (&event.xkey, buf, 4, &mp.X11Key, NULL) ;
XLookupString(&event.xkey, buf, 4, &mp.X11Key, NULL);
s32 idx = KeyMap.binary_search(mp);
@ -896,6 +896,7 @@ void CIrrDeviceLinux::setWindowCaption(const wchar_t* text)
XwcTextListToTextProperty(display, const_cast<wchar_t**>(&text), 1, XStdICCTextStyle, &txt);
XSetWMName(display, window, &txt);
XSetWMIconName(display, window, &txt);
XFree(txt.value);
#endif
}

View File

@ -15,7 +15,6 @@
#include "IAttributes.h"
#include "fast_atof.h"
#include "coreutil.h"
#include "irrMap.h"
namespace irr
{
@ -66,7 +65,6 @@ IAnimatedMesh* COBJMeshFileLoader::createMesh(io::IReadFile* file)
SObjMtl * currMtl = new SObjMtl();
Materials.push_back(currMtl);
u32 smoothingGroup=0;
core::map<video::S3DVertex, int> vertMap;
const core::stringc fullName = file->getFileName();
const core::stringc relPath = FileSystem->getFileDir(fullName)+"/";
@ -195,7 +193,7 @@ IAnimatedMesh* COBJMeshFileLoader::createMesh(io::IReadFile* file)
v.Normal.set(0.0f,0.0f,0.0f);
int vertLocation;
core::map<video::S3DVertex, int>::Node* n = vertMap.find(v);
core::map<video::S3DVertex, int>::Node* n = currMtl->VertMap.find(v);
if (n)
{
vertLocation = n->getValue();
@ -204,7 +202,7 @@ IAnimatedMesh* COBJMeshFileLoader::createMesh(io::IReadFile* file)
{
currMtl->Meshbuffer->Vertices.push_back(v);
vertLocation = currMtl->Meshbuffer->Vertices.size() -1;
vertMap.insert(v, vertLocation);
currMtl->VertMap.insert(v, vertLocation);
}
faceCorners.push_back(vertLocation);

View File

@ -10,6 +10,7 @@
#include "ISceneManager.h"
#include "irrString.h"
#include "SMeshBuffer.h"
#include "irrMap.h"
namespace irr
{
@ -58,6 +59,7 @@ private:
Meshbuffer->Material = o.Meshbuffer->Material;
}
core::map<video::S3DVertex, int> VertMap;
scene::SMeshBuffer *Meshbuffer;
core::stringc Name;
core::stringc Group;

View File

@ -171,9 +171,9 @@ bool COSOperator::getSystemMemory(u32* Total, u32* Avail) const
return false;
if (Total)
*Total = ((ps*(long long)pp)>>10);
*Total = (u32)((ps*(long long)pp)>>10);
if (Avail)
*Avail = ((ps*(long long)ap)>>10);
*Avail = (u32)((ps*(long long)ap)>>10);
return true;
#else
// TODO: implement for non-availablity of symbols/features

View File

@ -467,7 +467,11 @@ bool COpenGLExtensionHandler::queryFeature(E_VIDEO_DRIVER_FEATURE feature) const
case EVDF_ARB_GLSL:
return (FeatureAvailable[IRR_ARB_shading_language_100]||Version>=200);
case EVDF_TEXTURE_NPOT:
return (FeatureAvailable[IRR_ARB_texture_non_power_of_two]||Version>=200);
// Some ATI cards seem to have only SW support in OpenGL 2.0
// drivers if the extension is not exposed, so we skip this
// extra test for now!
// return (FeatureAvailable[IRR_ARB_texture_non_power_of_two]||Version>=200);
return (FeatureAvailable[IRR_ARB_texture_non_power_of_two]);
case EVDF_FRAMEBUFFER_OBJECT:
return FeatureAvailable[IRR_EXT_framebuffer_object];
case EVDF_VERTEX_BUFFER_OBJECT:

View File

@ -24,7 +24,7 @@ namespace irr
//! stub for calling createDeviceEx
IRRLICHT_API IrrlichtDevice* IRRCALLCONV createDevice(video::E_DRIVER_TYPE driverType,
const core::dimension2d<s32>& windowSize,
u32 bits, bool fullscreen,
u32 bits, bool fullscreen,
bool stencilbuffer, bool vsync, IEventReceiver* res,
const char* version)
{
@ -35,7 +35,7 @@ namespace irr
p.Fullscreen = fullscreen;
p.Stencilbuffer = stencilbuffer;
p.Vsync = vsync;
p.EventReceiver = res;
p.EventReceiver = res;
p.SDK_version_do_not_use = version;
return createDeviceEx(p);
@ -46,8 +46,8 @@ namespace irr
#if defined(_IRR_WINDOWS_API_)
BOOL APIENTRY DllMain( HANDLE hModule,
DWORD ul_reason_for_call,
BOOL APIENTRY DllMain( HANDLE hModule,
DWORD ul_reason_for_call,
LPVOID lpReserved )
{
// _crtBreakAlloc = 139;

View File

@ -108,7 +108,7 @@ REALINLINE void memcpy32_small ( void * dest, const void *source, u32 bytesize )
do
{
((u32*) dest ) [ c + -1 ] = ((u32*) source) [ c + -1 ];
((u32*) dest ) [ c-1 ] = ((u32*) source) [ c-1 ];
} while ( --c );
}