Browse Source

added a lib target

master
Joshua Moerman 12 years ago
parent
commit
fcad14e7bf
  1. 163
      ImageStreams.xcodeproj/project.pbxproj
  2. 79
      ImageStreams/ImageStreams.1
  3. 1
      README.md
  4. 0
      examples/main.cpp
  5. 2
      include/basics.hpp
  6. 0
      include/bmp.hpp
  7. 0
      include/jpg.hpp
  8. 0
      include/png.hpp

163
ImageStreams.xcodeproj/project.pbxproj

@ -7,12 +7,27 @@
objects = { objects = {
/* Begin PBXBuildFile section */ /* Begin PBXBuildFile section */
4263431015FA676F00977AF9 /* main.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4263430F15FA676F00977AF9 /* main.cpp */; }; 42212F6216064B920050F651 /* main.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 42212F6116064B920050F651 /* main.cpp */; };
4263431215FA676F00977AF9 /* ImageStreams.1 in CopyFiles */ = {isa = PBXBuildFile; fileRef = 4263431115FA676F00977AF9 /* ImageStreams.1 */; }; 42212F6716064BD20050F651 /* basics.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 42212F6316064BA00050F651 /* basics.hpp */; };
4263431C15FA6A3200977AF9 /* libpng.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4263431B15FA6A3200977AF9 /* libpng.framework */; }; 42212F6816064BD20050F651 /* bmp.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 42212F6416064BA00050F651 /* bmp.hpp */; };
4263431F1604CA3900977AF9 /* libjpeg.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 4263431E1604CA3900977AF9 /* libjpeg.a */; }; 42212F6916064BD20050F651 /* jpg.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 42212F6516064BA00050F651 /* jpg.hpp */; };
42212F6A16064BD20050F651 /* png.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 42212F6616064BA00050F651 /* png.hpp */; };
42212F6D16064C100050F651 /* libpng.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4263431B15FA6A3200977AF9 /* libpng.framework */; };
42212F6E16064C110050F651 /* libjpeg.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 4263431E1604CA3900977AF9 /* libjpeg.a */; };
42771697160649E700A9BFC8 /* libpng.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4263431B15FA6A3200977AF9 /* libpng.framework */; };
42771698160649E900A9BFC8 /* libjpeg.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 4263431E1604CA3900977AF9 /* libjpeg.a */; settings = {ATTRIBUTES = (Required, ); }; };
/* End PBXBuildFile section */ /* End PBXBuildFile section */
/* Begin PBXContainerItemProxy section */
42212F6B16064BEE0050F651 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 4263430215FA676F00977AF9 /* Project object */;
proxyType = 1;
remoteGlobalIDString = 42771692160649DF00A9BFC8;
remoteInfo = ImageStreams;
};
/* End PBXContainerItemProxy section */
/* Begin PBXCopyFilesBuildPhase section */ /* Begin PBXCopyFilesBuildPhase section */
4263430915FA676F00977AF9 /* CopyFiles */ = { 4263430915FA676F00977AF9 /* CopyFiles */ = {
isa = PBXCopyFilesBuildPhase; isa = PBXCopyFilesBuildPhase;
@ -20,22 +35,21 @@
dstPath = /usr/share/man/man1/; dstPath = /usr/share/man/man1/;
dstSubfolderSpec = 0; dstSubfolderSpec = 0;
files = ( files = (
4263431215FA676F00977AF9 /* ImageStreams.1 in CopyFiles */,
); );
runOnlyForDeploymentPostprocessing = 1; runOnlyForDeploymentPostprocessing = 1;
}; };
/* End PBXCopyFilesBuildPhase section */ /* End PBXCopyFilesBuildPhase section */
/* Begin PBXFileReference section */ /* Begin PBXFileReference section */
4263430B15FA676F00977AF9 /* ImageStreams */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = ImageStreams; sourceTree = BUILT_PRODUCTS_DIR; }; 42212F6116064B920050F651 /* main.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = main.cpp; path = examples/main.cpp; sourceTree = SOURCE_ROOT; };
4263430F15FA676F00977AF9 /* main.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = main.cpp; sourceTree = "<group>"; }; 42212F6316064BA00050F651 /* basics.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; name = basics.hpp; path = include/basics.hpp; sourceTree = SOURCE_ROOT; };
4263431115FA676F00977AF9 /* ImageStreams.1 */ = {isa = PBXFileReference; lastKnownFileType = text.man; path = ImageStreams.1; sourceTree = "<group>"; }; 42212F6416064BA00050F651 /* bmp.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; name = bmp.hpp; path = include/bmp.hpp; sourceTree = SOURCE_ROOT; };
4263431815FA679600977AF9 /* bmp.hpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.h; path = bmp.hpp; sourceTree = "<group>"; }; 42212F6516064BA00050F651 /* jpg.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; name = jpg.hpp; path = include/jpg.hpp; sourceTree = SOURCE_ROOT; };
4263431915FA67D500977AF9 /* png.hpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.h; path = png.hpp; sourceTree = "<group>"; }; 42212F6616064BA00050F651 /* png.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; name = png.hpp; path = include/png.hpp; sourceTree = SOURCE_ROOT; };
4263431A15FA686300977AF9 /* basics.hpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.h; path = basics.hpp; sourceTree = "<group>"; }; 4263430B15FA676F00977AF9 /* ImageStreams */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; name = ImageStreams; path = Examples; sourceTree = BUILT_PRODUCTS_DIR; };
4263431B15FA6A3200977AF9 /* libpng.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = libpng.framework; path = Library/Frameworks/libpng.framework; sourceTree = SDKROOT; }; 4263431B15FA6A3200977AF9 /* libpng.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = libpng.framework; path = Library/Frameworks/libpng.framework; sourceTree = SDKROOT; };
4263431D1604A79F00977AF9 /* jpg.hpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.h; path = jpg.hpp; sourceTree = "<group>"; };
4263431E1604CA3900977AF9 /* libjpeg.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libjpeg.a; path = ../../../../../usr/local/lib/libjpeg.a; sourceTree = "<group>"; }; 4263431E1604CA3900977AF9 /* libjpeg.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libjpeg.a; path = ../../../../../usr/local/lib/libjpeg.a; sourceTree = "<group>"; };
42771693160649DF00A9BFC8 /* libImageStreams.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libImageStreams.a; sourceTree = BUILT_PRODUCTS_DIR; };
/* End PBXFileReference section */ /* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */ /* Begin PBXFrameworksBuildPhase section */
@ -43,8 +57,17 @@
isa = PBXFrameworksBuildPhase; isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647; buildActionMask = 2147483647;
files = ( files = (
4263431C15FA6A3200977AF9 /* libpng.framework in Frameworks */, 42212F6D16064C100050F651 /* libpng.framework in Frameworks */,
4263431F1604CA3900977AF9 /* libjpeg.a in Frameworks */, 42212F6E16064C110050F651 /* libjpeg.a in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
42771690160649DF00A9BFC8 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
42771697160649E700A9BFC8 /* libpng.framework in Frameworks */,
42771698160649E900A9BFC8 /* libjpeg.a in Frameworks */,
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
}; };
@ -56,7 +79,8 @@
children = ( children = (
4263431E1604CA3900977AF9 /* libjpeg.a */, 4263431E1604CA3900977AF9 /* libjpeg.a */,
4263431B15FA6A3200977AF9 /* libpng.framework */, 4263431B15FA6A3200977AF9 /* libpng.framework */,
4263430E15FA676F00977AF9 /* ImageStreams */, 427716A016064A3100A9BFC8 /* examples */,
4263430E15FA676F00977AF9 /* include */,
4263430C15FA676F00977AF9 /* Products */, 4263430C15FA676F00977AF9 /* Products */,
); );
sourceTree = "<group>"; sourceTree = "<group>";
@ -65,29 +89,52 @@
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
4263430B15FA676F00977AF9 /* ImageStreams */, 4263430B15FA676F00977AF9 /* ImageStreams */,
42771693160649DF00A9BFC8 /* libImageStreams.a */,
); );
name = Products; name = Products;
sourceTree = "<group>"; sourceTree = "<group>";
}; };
4263430E15FA676F00977AF9 /* ImageStreams */ = { 4263430E15FA676F00977AF9 /* include */ = {
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
4263430F15FA676F00977AF9 /* main.cpp */, 42212F6316064BA00050F651 /* basics.hpp */,
4263431115FA676F00977AF9 /* ImageStreams.1 */, 42212F6416064BA00050F651 /* bmp.hpp */,
4263431A15FA686300977AF9 /* basics.hpp */, 42212F6516064BA00050F651 /* jpg.hpp */,
4263431815FA679600977AF9 /* bmp.hpp */, 42212F6616064BA00050F651 /* png.hpp */,
4263431915FA67D500977AF9 /* png.hpp */,
4263431D1604A79F00977AF9 /* jpg.hpp */,
); );
name = include;
path = ImageStreams;
sourceTree = "<group>";
};
427716A016064A3100A9BFC8 /* examples */ = {
isa = PBXGroup;
children = (
42212F6116064B920050F651 /* main.cpp */,
);
name = examples;
path = ImageStreams; path = ImageStreams;
sourceTree = "<group>"; sourceTree = "<group>";
}; };
/* End PBXGroup section */ /* End PBXGroup section */
/* Begin PBXHeadersBuildPhase section */
42771691160649DF00A9BFC8 /* Headers */ = {
isa = PBXHeadersBuildPhase;
buildActionMask = 2147483647;
files = (
42212F6716064BD20050F651 /* basics.hpp in Headers */,
42212F6816064BD20050F651 /* bmp.hpp in Headers */,
42212F6916064BD20050F651 /* jpg.hpp in Headers */,
42212F6A16064BD20050F651 /* png.hpp in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXHeadersBuildPhase section */
/* Begin PBXNativeTarget section */ /* Begin PBXNativeTarget section */
4263430A15FA676F00977AF9 /* ImageStreams */ = { 4263430A15FA676F00977AF9 /* Examples */ = {
isa = PBXNativeTarget; isa = PBXNativeTarget;
buildConfigurationList = 4263431515FA676F00977AF9 /* Build configuration list for PBXNativeTarget "ImageStreams" */; buildConfigurationList = 4263431515FA676F00977AF9 /* Build configuration list for PBXNativeTarget "Examples" */;
buildPhases = ( buildPhases = (
4263430715FA676F00977AF9 /* Sources */, 4263430715FA676F00977AF9 /* Sources */,
4263430815FA676F00977AF9 /* Frameworks */, 4263430815FA676F00977AF9 /* Frameworks */,
@ -96,12 +143,30 @@
buildRules = ( buildRules = (
); );
dependencies = ( dependencies = (
42212F6C16064BEE0050F651 /* PBXTargetDependency */,
); );
name = ImageStreams; name = Examples;
productName = ImageStreams; productName = ImageStreams;
productReference = 4263430B15FA676F00977AF9 /* ImageStreams */; productReference = 4263430B15FA676F00977AF9 /* ImageStreams */;
productType = "com.apple.product-type.tool"; productType = "com.apple.product-type.tool";
}; };
42771692160649DF00A9BFC8 /* ImageStreams */ = {
isa = PBXNativeTarget;
buildConfigurationList = 42771694160649DF00A9BFC8 /* Build configuration list for PBXNativeTarget "ImageStreams" */;
buildPhases = (
4277168F160649DF00A9BFC8 /* Sources */,
42771690160649DF00A9BFC8 /* Frameworks */,
42771691160649DF00A9BFC8 /* Headers */,
);
buildRules = (
);
dependencies = (
);
name = ImageStreams;
productName = ImageStreams;
productReference = 42771693160649DF00A9BFC8 /* libImageStreams.a */;
productType = "com.apple.product-type.library.static";
};
/* End PBXNativeTarget section */ /* End PBXNativeTarget section */
/* Begin PBXProject section */ /* Begin PBXProject section */
@ -123,7 +188,8 @@
projectDirPath = ""; projectDirPath = "";
projectRoot = ""; projectRoot = "";
targets = ( targets = (
4263430A15FA676F00977AF9 /* ImageStreams */, 4263430A15FA676F00977AF9 /* Examples */,
42771692160649DF00A9BFC8 /* ImageStreams */,
); );
}; };
/* End PBXProject section */ /* End PBXProject section */
@ -133,12 +199,27 @@
isa = PBXSourcesBuildPhase; isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647; buildActionMask = 2147483647;
files = ( files = (
4263431015FA676F00977AF9 /* main.cpp in Sources */, 42212F6216064B920050F651 /* main.cpp in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
4277168F160649DF00A9BFC8 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
}; };
/* End PBXSourcesBuildPhase section */ /* End PBXSourcesBuildPhase section */
/* Begin PBXTargetDependency section */
42212F6C16064BEE0050F651 /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = 42771692160649DF00A9BFC8 /* ImageStreams */;
targetProxy = 42212F6B16064BEE0050F651 /* PBXContainerItemProxy */;
};
/* End PBXTargetDependency section */
/* Begin XCBuildConfiguration section */ /* Begin XCBuildConfiguration section */
4263431315FA676F00977AF9 /* Debug */ = { 4263431315FA676F00977AF9 /* Debug */ = {
isa = XCBuildConfiguration; isa = XCBuildConfiguration;
@ -203,6 +284,22 @@
}; };
name = Release; name = Release;
}; };
42771695160649DF00A9BFC8 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
EXECUTABLE_PREFIX = lib;
PRODUCT_NAME = "$(TARGET_NAME)";
};
name = Debug;
};
42771696160649DF00A9BFC8 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
EXECUTABLE_PREFIX = lib;
PRODUCT_NAME = "$(TARGET_NAME)";
};
name = Release;
};
/* End XCBuildConfiguration section */ /* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */ /* Begin XCConfigurationList section */
@ -215,13 +312,23 @@
defaultConfigurationIsVisible = 0; defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release; defaultConfigurationName = Release;
}; };
4263431515FA676F00977AF9 /* Build configuration list for PBXNativeTarget "ImageStreams" */ = { 4263431515FA676F00977AF9 /* Build configuration list for PBXNativeTarget "Examples" */ = {
isa = XCConfigurationList; isa = XCConfigurationList;
buildConfigurations = ( buildConfigurations = (
4263431615FA676F00977AF9 /* Debug */, 4263431615FA676F00977AF9 /* Debug */,
4263431715FA676F00977AF9 /* Release */, 4263431715FA676F00977AF9 /* Release */,
); );
defaultConfigurationIsVisible = 0; defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
42771694160649DF00A9BFC8 /* Build configuration list for PBXNativeTarget "ImageStreams" */ = {
isa = XCConfigurationList;
buildConfigurations = (
42771695160649DF00A9BFC8 /* Debug */,
42771696160649DF00A9BFC8 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
}; };
/* End XCConfigurationList section */ /* End XCConfigurationList section */
}; };

79
ImageStreams/ImageStreams.1

@ -1,79 +0,0 @@
.\"Modified from man(1) of FreeBSD, the NetBSD mdoc.template, and mdoc.samples.
.\"See Also:
.\"man mdoc.samples for a complete listing of options
.\"man mdoc for the short list of editing options
.\"/usr/share/misc/mdoc.template
.Dd 9/7/12 \" DATE
.Dt ImageStreams 1 \" Program name and manual section number
.Os Darwin
.Sh NAME \" Section Header - required - don't modify
.Nm ImageStreams,
.\" The following lines are read in generating the apropos(man -k) database. Use only key
.\" words here as the database is built based on the words here and in the .ND line.
.Nm Other_name_for_same_program(),
.Nm Yet another name for the same program.
.\" Use .Nm macro to designate other names for the documented program.
.Nd This line parsed for whatis database.
.Sh SYNOPSIS \" Section Header - required - don't modify
.Nm
.Op Fl abcd \" [-abcd]
.Op Fl a Ar path \" [-a path]
.Op Ar file \" [file]
.Op Ar \" [file ...]
.Ar arg0 \" Underlined argument - use .Ar anywhere to underline
arg2 ... \" Arguments
.Sh DESCRIPTION \" Section Header - required - don't modify
Use the .Nm macro to refer to your program throughout the man page like such:
.Nm
Underlining is accomplished with the .Ar macro like this:
.Ar underlined text .
.Pp \" Inserts a space
A list of items with descriptions:
.Bl -tag -width -indent \" Begins a tagged list
.It item a \" Each item preceded by .It macro
Description of item a
.It item b
Description of item b
.El \" Ends the list
.Pp
A list of flags and their descriptions:
.Bl -tag -width -indent \" Differs from above in tag removed
.It Fl a \"-a flag as a list item
Description of -a flag
.It Fl b
Description of -b flag
.El \" Ends the list
.Pp
.\" .Sh ENVIRONMENT \" May not be needed
.\" .Bl -tag -width "ENV_VAR_1" -indent \" ENV_VAR_1 is width of the string ENV_VAR_1
.\" .It Ev ENV_VAR_1
.\" Description of ENV_VAR_1
.\" .It Ev ENV_VAR_2
.\" Description of ENV_VAR_2
.\" .El
.Sh FILES \" File used or created by the topic of the man page
.Bl -tag -width "/Users/joeuser/Library/really_long_file_name" -compact
.It Pa /usr/share/file_name
FILE_1 description
.It Pa /Users/joeuser/Library/really_long_file_name
FILE_2 description
.El \" Ends the list
.\" .Sh DIAGNOSTICS \" May not be needed
.\" .Bl -diag
.\" .It Diagnostic Tag
.\" Diagnostic informtion here.
.\" .It Diagnostic Tag
.\" Diagnostic informtion here.
.\" .El
.Sh SEE ALSO
.\" List links in ascending order by section, alphabetically within a section.
.\" Please do not reference files that do not exist without filing a bug report
.Xr a 1 ,
.Xr b 1 ,
.Xr c 1 ,
.Xr a 2 ,
.Xr b 2 ,
.Xr a 3 ,
.Xr b 3
.\" .Sh BUGS \" Document known, unremedied bugs
.\" .Sh HISTORY \" Document history if command behaves in a unique manner

1
README.md

@ -33,6 +33,7 @@ For the png format libpng is required. For the jpg format libjpeg or libjpeg-tur
TODO TODO
---- ----
* Make output iterators * Make output iterators
* Input streams (plus iterators)
* Add alpha support (where possible) * Add alpha support (where possible)
* Some interface for parameters (eg. jpg quality) * Some interface for parameters (eg. jpg quality)
* Add appropriate license * Add appropriate license

0
ImageStreams/main.cpp → examples/main.cpp

2
ImageStreams/basics.hpp → include/basics.hpp

@ -21,7 +21,7 @@
The order in the ctor is rgb even though the internal structure may be The order in the ctor is rgb even though the internal structure may be
different different
It should be trivially writable with memcpy (TODO: check exact requirement) It should be trivially copyable (for memcpy).
Furthermore it should have a static constexpr size_t num_colors indicating the Furthermore it should have a static constexpr size_t num_colors indicating the
number of colors and a static constexpr size_t bit_per_color indicating the number of colors and a static constexpr size_t bit_per_color indicating the

0
ImageStreams/bmp.hpp → include/bmp.hpp

0
ImageStreams/jpg.hpp → include/jpg.hpp

0
ImageStreams/png.hpp → include/png.hpp