All Versions
41
Latest Version
Avg Release Cycle
91 days
Latest Release
1006 days ago
Changelog History
Page 4
Changelog History
Page 4
-
v0.11 Changes
April 04, 2015- Clarify with documentation comments various constructors produced by the
Parser
- Add
SharedPtrAdapter
and corresponding@SharedPtr
annotation to supportshared_ptr
containers - Fix a few small issues and work around a few additional corner cases with the
Parser
and theGenerator
- Provide
UByteIndexer
andUShortIndexer
, treating array and buffer data as unsigned integers, for ease of use - Clean up Windows
java.io.tmpdir
even when program messes withjava.class.path
(issue #12) - In addition to direct NIO buffers, also accept as function arguments non-direct ones backed by arrays (issue bytedeco/javacpp-presets#36)
- Fix
@Virtual
callback functions defined inside a@Namespace
- Adjust
TokenIndexer
andParser
to handle#if
,#ifdef
,#ifndef
,#elif
,#else
, and#endif
preprocessor directives more appropriately, even when placed in the middle of declarations - Append
@Documented
to annotation types to have them picked up by Javadoc - Fix
friend
functions not getting skipped by theParser
- Add
Info
for__int8
,__int16
,__int32
, and__int64
toInfoMap.defaults
- Clarify with documentation comments various constructors produced by the
-
v0.10 Changes
December 23, 2014- Fix multiple "platform.preload" or "platform.preloadpath" properties not getting considered by the
Loader
- Fix some
Parser
exceptions on valid declarations with template arguments, macro expansions, or overloaded cast operators, and makeInfo.javaName
usable in the case ofenum
- Disable DocLint, which prevents the build from succeeding on Java 8 (issue #5)
- Add new
indexer
package containing a set ofIndexer
for easy and efficient multidimensional access of arrays and buffers (issue javacv:317) - Use
Long.decode()
inside theTokenizer
to test more precisely when integer values are larger than 32 bits - Have the
Parser
produce@Name("operator=") ... put(... )
methods for standard C++ containers, avoiding mistaken calls toPointer.put(Pointer)
(issue bytedeco/javacv#34) - Let the
Parser
applyInfo.skip
in the case of macros as well - Remove warning log messages when using the
@Raw
annotation - Let
@Virtual @MemberGetter
annotated methods return member function pointers of functions defined with@Virtual
, useful for frameworks like Cocos2d-x - Fix
NullPointerException
when leaving theincludePath
,linkPath
, orpreloadPath
Mojo parameter empty - Add
Info.virtualize
to have theParser
generate@Virtual abstract
for pure virtual functions in the given classes - Add
@Virtual
annotation and updateGenerator
to support callback by overriding such annotatednative
orabstract
methods - Add hack for
typedef void*
definitions and parameters with a double indirection to them
- Fix multiple "platform.preload" or "platform.preloadpath" properties not getting considered by the
-
v0.9 Changes
July 27, 2014- Fix
Generator.checkPlatform()
not checking super classes - Add
includePath
,linkPath
, andpreloadPath
parameters toBuildMojo
to let Maven users append paths to the properties easily - In consequence, remove too arbitrary "local" paths from the default platform properties (issue #43)
- Fix a few other more or less minor issues in the
Parser
with thelong double
,ptrdiff_t
,intptr_t
,uintptr_t
,off_t
types, floating-point numbers, macro redefinitions, access specifiers, casting of const values by reference, optional parentheses, const data types in templates, declarator names equal to a type name, friend functions, inline constructors,typedef void
declarations within namespaces, pointers to function pointers - Allow users to instruct the
Parser
to skip the expansion of specific macro invocations - Let
Parser
concatenate tokens when expanding macros containing the##
operator - Add some documentation for
Info
,InfoMap
,InfoMapper
, andParser
- Fix the
Parser
not filtering and expanding properly some preprocessor directives, as well as producing wrong code fortypedef struct *
- Skip Java path search when building for Android to prevent including some random
jni.h
file (issue #3) - Fix the
Parser
losing some keywords likestatic
on methods annotated with an@Adapter
(issue #2) - Fix
Loader.load()
not properly force loading all inherited target classes (issue #1)
- Fix
-
v0.8 Changes
April 28, 2014- Move from Google Code to GitHub as main source code repository
- Place build-time classes in the
org.bytedeco.javacpp.tools
package and bring out static nested classes, in an effort to avoid conflicts and ease development - Rename the
com.googlecode.javacpp
package toorg.bytedeco.javacpp
- Added
public long Pointer.address()
getter method, useful when one needs to subtract two pointers - Removed old NetBeans project files that cause a conflict when trying to open as a Maven project (issue javacv:210)
- Fixed compilation error on
FunctionPointer
classes containing no native callback methods - Added a
platform.library.path
property, such as "lib/armeabi/" in the case of the "android-arm" platform, to be used instead of "package/platform" (issue javacv:427) - Generalized references to the path of the Android NDK
- Improved a few small things in the set of
Pointer
classes - Introduced a simple
Logger
class and unified the logging output calls around it - Unified the property names with the
@Properties
and@Platform
annotations into a consistent naming scheme - Continued to clean up the
Parser
and improve the support of, for the most part, comments, enumerations, functions pointers, anonymousstruct
orunion
, templates, overloaded operators, namespaces, standard containers, default parameter arguments, multiple inheritance, custom names of wrapped declarators, and helper classes written in Java - Annotations such as
@Adapter
or@ByVal
are no longer ignored on parameters of getters or setters annotated with@Index
- Fixed some other corner cases in
Generator
and a few potential issues with the hacks inLoader
- Added for convenience to
PointerPointer
a generic parameter<P extends Pointer>
and the associatedget(Class<P> ...)
getters, as well asString
getters and setters - Passing a
Class
object as first argument to a native method that returns aPointer
now determines the runtime type of that returned object - Generalized somewhat more the compiler options used inside
linux-arm.properties
(issue javacv:418) - Unified the function pointer type of native deallocators to
void (*)(void*)
- Removed dependency on (efficient)
AllocObject()
andCallNonvirtualVoidMethodA()
JNI functions, which are not supported by Avian - Cleaned up and optimized
Generator
a bit, also fixing a crash that could occur whenFindClass()
returnsNULL
-
v0.7 Changes
January 06, 2014- Tweaked a few things to support RoboVM and target iOS, but
JNI_OnLoad()
does not appear to get called... - Upgraded references of the Android NDK to version r9c
- Made
Loader.load()
work, within reason, even when all annotations and resources have been removed, for example, by ProGuard - Fixed compile error when using a
FunctionPointer
as parameter from outside its top-level enclosing class - Added new
Pointer.deallocate(false)
call to disable garbage collection on a per object basis, allowing users to deal with memory leaks in other ways - Changed the default compiler option
-mfpu=vfpv
for ARM to-mfpu=vfpv3-d16
, because the former is not supported by Tegra 2 (issue javacv:366) - Removed call to
Arrays.copyOf()
inLoader.findLibrary()
, which would prevent it from working on Android 2.2 (issue #39) - Fixed invalid code generated for
FunctionPointer
parameters annotated with@Const @ByRef
- Fixed
NullPointerException
inLoader.load()
when no@Platform
annotation is provided (issue #38) - Parsing for anonymous
struct
orunion
and fortypedef void
(mapped to@Opaque Pointer
) now outputs something - The
Parser
now expands preprocessor macros, filters tokens appropriately, and outputs all unprocessed directives as comments - Improved the C++ support of the
Parser
for namespaces, derived classes, access specifiers, custom constructors, vector types, macros, templates, overloaded operators, etc - Fixed
typedef
of function pointers and a few code formatting issues withParser
- Supplied checks to prevent
Loader.load()
from throwingjava.lang.IllegalStateException: Can't overwrite cause
- Tweaked a few things to support RoboVM and target iOS, but
-
v0.6 Changes
September 15, 2013- Added new very preliminary
Parser
to produce Java interface files almost automatically from C/C++ header files; please refer to the new JavaCPP Presets subproject for details - When catching a C++ exception, the first class declared after
throws
now gets thrown (issue #36) instead ofRuntimeException
, which is still used by default - Fixed Java resource leak after catching a C++ exception
- Upgraded references of the Android NDK to version r9
- Added new
Builder
option "-copylibs" that copies into the build directory any dependent shared libraries listed in the@Platform(link={...}, preload={...})
annotation Loader.getPlatformName()
can now be overridden by setting thecom.googlecode.javacpp.platform.name
system property- Refactored the loading code for
@Properties()
into a neatLoader.ClassProperties
class, among a few other small changes inLoader
,Builder
,Generator
, and the properties - Included often used directories such as
/usr/local/include/
and/usr/local/lib/
tocompiler.includepath
andcompiler.linkpath
default properties - New
@Properties(inherit={Class})
value lets users specify properties in common on a similarly annotated shared config class of sorts - Fixed callbacks when used with custom class loaders such as with Web containers or frameworks like Tomcat and Play
- Fixed using
@StdString
(or other@Adapter
with@Cast
annotations) on callbacks (issue #34), incidentally allowing them to return aString
- By default,
Builder
now links to thejvm
library only when required, when using the-header
command line option (issue #33) - Incorporated missing explicit cast on return values when using the
@Cast
annotation - Fixed duplicate code getting generated when both specifying the output filename with
-o <name>
and using wildcards on packages containing nested classes - Let
Buffer
or arrays of primitive values be valid return and callback arguments, mostly useful when used along with the@StdVector
annotation, or some other custom adapter
- Added new very preliminary
-
v0.5 Changes
April 07, 2013- Upgraded references of the Android NDK to version r8e
- Arguments of
Pointer
type now get handled aschar*
in cases when theposition
can be used for arithmetic - Worked around bug of
InputStream.available()
always returning 0 with thehttp
protocol inLoader.extractResource(URL)
-
v0.4 Changes
March 03, 2013- Fixed potential problem with methods of
FunctionPointer
annotated with@Cast("const...")
- Upgraded references of the Android NDK to version r8d
- Fixed callbacks not working on Android anymore (issue #30)
- Added some Javadoc to most of the code
- To help diagnose
UnsatisfiedLinkError
thrown byLoader.load()
, they have been augmented with a potential cause originating from the "preloading" of libraries, whose premature deletion has also been fixed - Provided new
@Platform(library="...")
annotation value to let users specify the name of the native library used by bothBuilder
andLoader
, where different classes with the same name get built together, which also works on nested classes (issue #29) - Added the ability to change the name of the class of function objects created when defining a
FunctionPointer
with the@Name
annotation Builder
would go on a compile spree when all classes specified on the command line could not be loaded- Exported
Loader.isLoadLibraries()
, which always returns true, except when theBuilder
loads the classes - Made it possible to specify a nested class (with a '$' character in the name) on the command line
- When
Pointer.limit == 0
, the methodsput()
,zero()
, andasBuffer()
now assume a size of 1 - Fixed compiler error on 32-bit Mac OS X
- Fixed potential problem with methods of
-
v0.3 Changes
November 04, 2012- Added
Pointer.withDeallocator(Pointer)
method to attach easily a customDeallocator
created out of astatic void deallocate(Pointer)
method in the subclass, including native ones such as@Namespace @Name("delete") static native void deallocate(Pointer)
- A name starting with "::", for example
@Name("::std::string")
or@Namespace("::std")
, now drops the remaining enclosing scope - Removed confusing
cast
value of@Adapter
instead relying on newString[]
value of@Cast
to order multiple casts - Renamed various variables in
Generator
to make the generated code more readable - Fixed memory corruption when using an adapter or
@ByRef
on a function that returns by value anstd::vector<>
orstd::string
(issue #26) - Added
Pointer.zero()
method that callsmemset(0)
on the range - For easier memory management, more than one
Pointer
now allowed to share thedeallocator
when "casting" them - Upgraded references of the Android NDK to version r8b
- Fixed
JavaCPP_log()
not printing correctly (issue #27) - Added functionality to access easily
FunctionPointer
callbacks by their names from C/C++: We can annotate them with@Name
and build with the new-header
option to get their declarations in a header file, while theBuilder
links with thejvm
library by default Loader
now displays an informative error message when trying to use an undefinedcompiler.options
with@Platform(options="")
(issue #24)Pointer.deallocator()
would needlessly enqueueDeallocator
objects pointing to the nativeNULL
address- Added support for C++ "functors" based on the
operator()
, which gets used when annotating aFunctionPointer
method parameter with@ByRef
or@ByVal
- For convenience in Scala, added
apply()
as an acceptable caller method name within aFunctionPointer
, in addition tocall()
- Fixed
@Cast
not working along parameters with an@Adapter
or when attempting toreturn
the argument Generator
would ignorePointer.position()
in the case of@ByPtrPtr
and@ByPtrRef
parameters- Replaced hack to create a
Pointer
from aBuffer
object with something more standard - Fixed
Loader.sizeof(Pointer.class)
to return thesizeof(void*)
- In addition to methods and parameters, we may now apply
@Adapter
to annotation types as well, allowing us to shorten expressions like@Adapter("VectorAdapter<int>") int[]
to just@StdVector int[]
, forstd::vector<int>
support, and similarly for@StdString
andstd::string
- Fixed callback parameter casting of primitive and
String
types - An empty
@Namespace
can now be used to letGenerator
know of entities that are not part of any scope, such as macros and operators - Turned
FunctionPointer
into anabstract class
withprotected
constructors, but if users still try to use it as function parameters,Generator
now logs a warning indicating that a subclass should be used (issue #23) - Removed the
out
value of the@Adapter
annotation: All adapters are now "out" by default, unless@Const
also appears on the same element - Fixed
Pointer.equals(null)
throwingNullPointerException
(issue #22) @NoOffset
would erroneously preventsizeof()
operations from getting generated
- Added
-
v0.2 Changes
July 21, 2012- Fixed problems when trying to map
java.lang.String
to other native types thanchar*
, such asunsigned char*
- JavaCPP now uses the
new (std::nothrow)
operator for allocation, which guarantees that allocation of primitive native arrays won't throw exceptions, making it possible to build C++ exception free JNI libraries - Added new
Pointer.limit
property, mainly useful to get thesize
of an output parameter, as returned by an adapter specified with the@Adapter
annotation - Renamed the
capacity
field of an adapter tosize
as it now maps to bothPointer.limit
andPointer.capacity
(the latter only for new allocations) - Added
Pointer.put(Pointer)
method, the counterpart ofBuffer.put(Buffer)
, to call the nativememcpy()
function on twoPointer
objects - New
@NoException
annotation to reduce the size of generated code and optimize runtime performance of functions that are guaranteed not to throw exceptions, or for cases when we do not mind that the JVM may crash and burn - Trying to generate code for non-static native methods inside a class not extending
Pointer
now generates proper warning (issue #19) - Fixed regression where the
@Adapter
notation generates incorrect code for types other thanPointer
(issue #20)
- Fixed problems when trying to map