iOS: fix patches (maybe)

This commit is contained in:
Maksim Gamarnik 2016-12-11 17:02:43 +02:00
parent e0177a7c6e
commit 13d4a1f341
4 changed files with 80 additions and 80 deletions

18
build/iOS/patches/irrlicht-dblfreefix.patch Normal file → Executable file
View File

@ -1,12 +1,12 @@
--- source/Irrlicht/COpenGLCoreCacheHandler.h.orig 2016-10-25 15:42:40.000000000 +0200 --- source/Irrlicht/COpenGLCoreCacheHandler.h.orig 2016-10-25 15:42:40.000000000 +0200
+++ source/Irrlicht/COpenGLCoreCacheHandler.h 2016-10-25 15:52:13.000000000 +0200 +++ source/Irrlicht/COpenGLCoreCacheHandler.h 2016-10-25 15:52:13.000000000 +0200
@@ -115,9 +115,6 @@ @@ -115,9 +115,6 @@
} }
Texture[index] = static_cast<const TOpenGLTexture*>(texture); Texture[index] = static_cast<const TOpenGLTexture*>(texture);
- -
- if (prevTexture) - if (prevTexture)
- prevTexture->drop(); - prevTexture->drop();
} }
status = true; status = true;

86
build/iOS/patches/irrlicht-touchcount.patch Normal file → Executable file
View File

@ -1,52 +1,52 @@
--- include/IEventReceiver.h.orig 2016-10-21 00:07:27.000000000 +0200 --- include/IEventReceiver.h.orig 2016-10-21 00:07:27.000000000 +0200
+++ include/IEventReceiver.h 2016-10-21 00:08:40.000000000 +0200 +++ include/IEventReceiver.h 2016-10-21 00:08:40.000000000 +0200
@@ -417,6 +417,9 @@ @@ -417,6 +417,9 @@
// Y position of simple touch. // Y position of simple touch.
s32 Y; s32 Y;
+ // Number of current touches + // Number of current touches
+ s32 touchedCount; + s32 touchedCount;
+ +
//! Type of touch event. //! Type of touch event.
ETOUCH_INPUT_EVENT Event; ETOUCH_INPUT_EVENT Event;
}; };
--- source/Irrlicht/CIrrDeviceiOS.mm.orig 2016-10-21 00:07:45.000000000 +0200 --- source/Irrlicht/CIrrDeviceiOS.mm.orig 2016-10-21 00:07:45.000000000 +0200
+++ source/Irrlicht/CIrrDeviceiOS.mm 2016-10-21 00:10:07.000000000 +0200 +++ source/Irrlicht/CIrrDeviceiOS.mm 2016-10-21 00:10:07.000000000 +0200
@@ -202,6 +202,7 @@ @@ -202,6 +202,7 @@
irr::SEvent ev; irr::SEvent ev;
ev.EventType = irr::EET_TOUCH_INPUT_EVENT; ev.EventType = irr::EET_TOUCH_INPUT_EVENT;
ev.TouchInput.Event = irr::ETIE_PRESSED_DOWN; ev.TouchInput.Event = irr::ETIE_PRESSED_DOWN;
+ ev.TouchInput.touchedCount = [touches count]; + ev.TouchInput.touchedCount = [touches count];
for (UITouch* touch in touches) for (UITouch* touch in touches)
{ {
@@ -220,7 +221,8 @@ @@ -220,7 +221,8 @@
{ {
irr::SEvent ev; irr::SEvent ev;
ev.EventType = irr::EET_TOUCH_INPUT_EVENT; ev.EventType = irr::EET_TOUCH_INPUT_EVENT;
- ev.TouchInput.Event = irr::ETIE_MOVED; - ev.TouchInput.Event = irr::ETIE_MOVED;
+ ev.TouchInput.Event = irr::ETIE_MOVED; + ev.TouchInput.Event = irr::ETIE_MOVED;
+ ev.TouchInput.touchedCount = [touches count]; + ev.TouchInput.touchedCount = [touches count];
for (UITouch* touch in touches) for (UITouch* touch in touches)
{ {
@@ -239,7 +241,8 @@ @@ -239,7 +241,8 @@
{ {
irr::SEvent ev; irr::SEvent ev;
ev.EventType = irr::EET_TOUCH_INPUT_EVENT; ev.EventType = irr::EET_TOUCH_INPUT_EVENT;
- ev.TouchInput.Event = irr::ETIE_LEFT_UP; - ev.TouchInput.Event = irr::ETIE_LEFT_UP;
+ ev.TouchInput.Event = irr::ETIE_LEFT_UP; + ev.TouchInput.Event = irr::ETIE_LEFT_UP;
+ ev.TouchInput.touchedCount = [touches count]; + ev.TouchInput.touchedCount = [touches count];
for (UITouch* touch in touches) for (UITouch* touch in touches)
{ {
@@ -258,7 +261,8 @@ @@ -258,7 +261,8 @@
{ {
irr::SEvent ev; irr::SEvent ev;
ev.EventType = irr::EET_TOUCH_INPUT_EVENT; ev.EventType = irr::EET_TOUCH_INPUT_EVENT;
- ev.TouchInput.Event = irr::ETIE_LEFT_UP; - ev.TouchInput.Event = irr::ETIE_LEFT_UP;
+ ev.TouchInput.Event = irr::ETIE_LEFT_UP; + ev.TouchInput.Event = irr::ETIE_LEFT_UP;
+ ev.TouchInput.touchedCount = [touches count]; + ev.TouchInput.touchedCount = [touches count];
for (UITouch* touch in touches) for (UITouch* touch in touches)
{ {

16
build/iOS/patches/irrlicht-unscaled.patch Normal file → Executable file
View File

@ -1,11 +1,11 @@
--- source/Irrlicht/CIrrDeviceiOS.mm.orig 2016-10-21 13:27:51.000000000 +0200 --- source/Irrlicht/CIrrDeviceiOS.mm.orig 2016-10-21 13:27:51.000000000 +0200
+++ source/Irrlicht/CIrrDeviceiOS.mm 2016-10-21 13:28:14.000000000 +0200 +++ source/Irrlicht/CIrrDeviceiOS.mm 2016-10-21 13:28:14.000000000 +0200
@@ -186,7 +186,7 @@ @@ -186,7 +186,7 @@
if (self) if (self)
{ {
Device = device; Device = device;
- Scale = ([self respondsToSelector:@selector(setContentScaleFactor:)]) ? [[UIScreen mainScreen] scale] : 1.f; - Scale = ([self respondsToSelector:@selector(setContentScaleFactor:)]) ? [[UIScreen mainScreen] scale] : 1.f;
+ Scale = 1.f; + Scale = 1.f;
} }
return self; return self;

40
build/iOS/patches/irrlicht-viewcontroller.patch Normal file → Executable file
View File

@ -1,26 +1,26 @@
--- source/Irrlicht/CIrrDeviceiOS.h.bak 2016-11-21 17:59:52.000000000 +0100 --- source/Irrlicht/CIrrDeviceiOS.h.bak 2016-11-21 17:59:52.000000000 +0100
+++ source/Irrlicht/CIrrDeviceiOS.h 2016-11-21 18:06:06.000000000 +0100 +++ source/Irrlicht/CIrrDeviceiOS.h 2016-11-21 18:06:06.000000000 +0100
@@ -61,6 +61,8 @@ @@ -61,6 +61,8 @@
virtual E_DEVICE_TYPE getType() const _IRR_OVERRIDE_; virtual E_DEVICE_TYPE getType() const _IRR_OVERRIDE_;
+ void *getViewController(); + void *getViewController();
+ +
private: private:
void createWindow(); void createWindow();
void createViewAndDriver(); void createViewAndDriver();
--- source/Irrlicht/CIrrDeviceiOS.mm.bak 2016-11-21 18:00:26.000000000 +0100 --- source/Irrlicht/CIrrDeviceiOS.mm.bak 2016-11-21 18:00:26.000000000 +0100
+++ source/Irrlicht/CIrrDeviceiOS.mm 2016-11-21 18:06:35.000000000 +0100 +++ source/Irrlicht/CIrrDeviceiOS.mm 2016-11-21 18:06:35.000000000 +0100
@@ -687,6 +687,12 @@ @@ -687,6 +687,12 @@
return EIDT_IOS; return EIDT_IOS;
} }
+ void *CIrrDeviceiOS::getViewController() + void *CIrrDeviceiOS::getViewController()
+ { + {
+ SIrrDeviceiOSDataStorage* dataStorage = static_cast<SIrrDeviceiOSDataStorage*>(DataStorage); + SIrrDeviceiOSDataStorage* dataStorage = static_cast<SIrrDeviceiOSDataStorage*>(DataStorage);
+ return (__bridge void*) dataStorage->ViewController; + return (__bridge void*) dataStorage->ViewController;
+ } + }
+ +
void CIrrDeviceiOS::createWindow() void CIrrDeviceiOS::createWindow()
{ {
if (CreationParams.DriverType != video::EDT_NULL) if (CreationParams.DriverType != video::EDT_NULL)