Skip to content

Commit

Permalink
Updated image_base to Allacrost v0.1.0 to fix color issues. Also upda…
Browse files Browse the repository at this point in the history
…ted to libpng15.
  • Loading branch information
Socapex committed Feb 23, 2013
1 parent a254ef6 commit 111575c
Show file tree
Hide file tree
Showing 3 changed files with 726 additions and 570 deletions.
8 changes: 0 additions & 8 deletions Xcode/ValyriaTear.xcodeproj/project.pbxproj
Expand Up @@ -7,7 +7,6 @@
objects = {

/* Begin PBXBuildFile section */
2B33A49F16D836BC00197E24 /* art in Resources */ = {isa = PBXBuildFile; fileRef = 2B33A49E16D836BC00197E24 /* art */; };
2B33A4A116D836FE00197E24 /* img in Resources */ = {isa = PBXBuildFile; fileRef = 2B33A4A016D836FE00197E24 /* img */; };
2B33A4A416D8370900197E24 /* mus in Resources */ = {isa = PBXBuildFile; fileRef = 2B33A4A216D8370900197E24 /* mus */; };
2B33A4A516D8370900197E24 /* snd in Resources */ = {isa = PBXBuildFile; fileRef = 2B33A4A316D8370900197E24 /* snd */; };
Expand Down Expand Up @@ -89,7 +88,6 @@
2B33A6F116D8376A00197E24 /* shop_utils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2B33A62B16D8376A00197E24 /* shop_utils.cpp */; };
2B33A6F216D8376A00197E24 /* SDLMain.m in Sources */ = {isa = PBXBuildFile; fileRef = 2B33A62E16D8376A00197E24 /* SDLMain.m */; };
2B33A6F416D8376A00197E24 /* utils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2B33A63216D8376A00197E24 /* utils.cpp */; };
2B33A7D816D846B700197E24 /* .gitignore in Resources */ = {isa = PBXBuildFile; fileRef = 2B33A6F816D846B600197E24 /* .gitignore */; };
2B33A7D916D846B700197E24 /* config.log in Resources */ = {isa = PBXBuildFile; fileRef = 2B33A6FA16D846B600197E24 /* config.log */; };
2B33A7EC16D846B700197E24 /* adopt.rst in Resources */ = {isa = PBXBuildFile; fileRef = 2B33A71116D846B600197E24 /* adopt.rst */; };
2B33A7ED16D846B700197E24 /* building.rst in Resources */ = {isa = PBXBuildFile; fileRef = 2B33A71216D846B600197E24 /* building.rst */; };
Expand Down Expand Up @@ -167,7 +165,6 @@
2B33A46D16D8361700197E24 /* libogg.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libogg.a; path = libs/libogg.a; sourceTree = "<group>"; };
2B33A46E16D8361700197E24 /* libpng15.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libpng15.a; path = libs/libpng15.a; sourceTree = "<group>"; };
2B33A46F16D8361700197E24 /* libvorbis.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libvorbis.a; path = libs/libvorbis.a; sourceTree = "<group>"; };
2B33A49E16D836BC00197E24 /* art */ = {isa = PBXFileReference; lastKnownFileType = folder; name = art; path = ../../art; sourceTree = "<group>"; };
2B33A4A016D836FE00197E24 /* img */ = {isa = PBXFileReference; lastKnownFileType = folder; name = img; path = ../../img; sourceTree = "<group>"; };
2B33A4A216D8370900197E24 /* mus */ = {isa = PBXFileReference; lastKnownFileType = folder; name = mus; path = ../../mus; sourceTree = "<group>"; };
2B33A4A316D8370900197E24 /* snd */ = {isa = PBXFileReference; lastKnownFileType = folder; name = snd; path = ../../snd; sourceTree = "<group>"; };
Expand Down Expand Up @@ -334,7 +331,6 @@
2B33A63216D8376A00197E24 /* utils.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = utils.cpp; sourceTree = "<group>"; };
2B33A63316D8376A00197E24 /* utils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = utils.h; sourceTree = "<group>"; };
2B33A6F516D840DD00197E24 /* libluabindd.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libluabindd.a; path = libs/libluabindd.a; sourceTree = "<group>"; };
2B33A6F816D846B600197E24 /* .gitignore */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = .gitignore; sourceTree = "<group>"; };
2B33A6FA16D846B600197E24 /* config.log */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = config.log; sourceTree = "<group>"; };
2B33A6FE16D846B600197E24 /* class.o */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.objfile"; path = class.o; sourceTree = "<group>"; };
2B33A6FF16D846B600197E24 /* class_info.o */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.objfile"; path = class_info.o; sourceTree = "<group>"; };
Expand Down Expand Up @@ -806,7 +802,6 @@
2B33A6F716D846B600197E24 /* luabind */ = {
isa = PBXGroup;
children = (
2B33A6F816D846B600197E24 /* .gitignore */,
2B33A6F916D846B600197E24 /* bin */,
2B33A71016D846B600197E24 /* doc */,
2B33A73F16D846B600197E24 /* INSTALL */,
Expand Down Expand Up @@ -1071,7 +1066,6 @@
2B33A4A216D8370900197E24 /* mus */,
2B33A4A316D8370900197E24 /* snd */,
2B33A4A016D836FE00197E24 /* img */,
2B33A49E16D836BC00197E24 /* art */,
2BA1775B16D8330400163B97 /* AppDelegate.h */,
2BA1775C16D8330400163B97 /* AppDelegate.m */,
2BA1775E16D8330500163B97 /* MainMenu.xib */,
Expand Down Expand Up @@ -1146,13 +1140,11 @@
2BA1775416D8330400163B97 /* InfoPlist.strings in Resources */,
2BA1775A16D8330400163B97 /* Credits.rtf in Resources */,
2BA1776016D8330500163B97 /* MainMenu.xib in Resources */,
2B33A49F16D836BC00197E24 /* art in Resources */,
2B33A4A116D836FE00197E24 /* img in Resources */,
2B33A4A416D8370900197E24 /* mus in Resources */,
2B33A4A516D8370900197E24 /* snd in Resources */,
2B33A4A916D8372C00197E24 /* mac_logo.icns in Resources */,
2B33A63416D8376A00197E24 /* CMakeLists.txt in Resources */,
2B33A7D816D846B700197E24 /* .gitignore in Resources */,
2B33A7D916D846B700197E24 /* config.log in Resources */,
2B33A7EC16D846B700197E24 /* adopt.rst in Resources */,
2B33A7ED16D846B700197E24 /* building.rst in Resources */,
Expand Down

3 comments on commit 111575c

@Bertram25
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi, there is no useful difference in image_base.h. I'll check the cpp file.

@Bertram25
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@socapex,

Ok, I've checked both version after reformatting the allacrost one against the new indentation format. The only meaningful change is coming as I thought from the pixel order loaded depending on the computer endianess.

So, could you revert the changes made there, as they break libpng1.5 support for sure, and rather try to tweak the pixel loading order at this very place?
https://github.com/Bertram25/ValyriaTear/blob/master/src/engine/video/image_base.cpp#L106
(between #if SDL_BYTEORDER == SDL_BIG_ENDIAN and #endif)

(I don't know which endianess you have, but it must be the one I can't test, eh ;])
To do that you'll have to test which endianess is used for you and make change in the pixel order, by assigning the dst_pixel[] values until you find the correct combination.

I'll have a look at the luabind differences now.

@p-groarke
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have converted this to libpng1.5 (I went through and changed all info_ptr to the png_get* methods). I will definitely revert image_base and work it out with minor changes, this is top priority on my todo list :)

I had also tried BGRA and INT_8_8_8_8_REV etc. But Allacrost uses its own way to load files (instead of the more usual RGBAFormat).

Please sign in to comment.