mirror of
https://github.com/opencv/opencv.git
synced 2024-11-29 05:29:54 +08:00
Merge pull request #477 from asmorkalov:android_version_info
This commit is contained in:
commit
8b7a28a7e4
@ -255,7 +255,7 @@ The function allocates the buffer of the specified size and returns it. When the
|
|||||||
|
|
||||||
|
|
||||||
fastFree
|
fastFree
|
||||||
------------
|
--------
|
||||||
Deallocates a memory buffer.
|
Deallocates a memory buffer.
|
||||||
|
|
||||||
.. ocv:function:: void fastFree(void* ptr)
|
.. ocv:function:: void fastFree(void* ptr)
|
||||||
@ -280,6 +280,14 @@ The function acts like ``sprintf`` but forms and returns an STL string. It can
|
|||||||
:ocv:class:`Exception` constructor.
|
:ocv:class:`Exception` constructor.
|
||||||
|
|
||||||
|
|
||||||
|
getBuildInformation
|
||||||
|
-------------------
|
||||||
|
Returns full configuration time cmake output.
|
||||||
|
|
||||||
|
.. ocv:function:: const std::string& getBuildInformation()
|
||||||
|
|
||||||
|
Returned value is raw cmake output including version control system revision, compiler version, compiler flags, enabled modules and third party libraries, etc. Output format depends on target architecture.
|
||||||
|
|
||||||
|
|
||||||
checkHardwareSupport
|
checkHardwareSupport
|
||||||
--------------------
|
--------------------
|
||||||
@ -304,7 +312,7 @@ Returns true if the specified feature is supported by the host hardware.
|
|||||||
The function returns true if the host hardware supports the specified feature. When user calls ``setUseOptimized(false)``, the subsequent calls to ``checkHardwareSupport()`` will return false until ``setUseOptimized(true)`` is called. This way user can dynamically switch on and off the optimized code in OpenCV.
|
The function returns true if the host hardware supports the specified feature. When user calls ``setUseOptimized(false)``, the subsequent calls to ``checkHardwareSupport()`` will return false until ``setUseOptimized(true)`` is called. This way user can dynamically switch on and off the optimized code in OpenCV.
|
||||||
|
|
||||||
getNumThreads
|
getNumThreads
|
||||||
-----------------
|
-------------
|
||||||
Returns the number of threads used by OpenCV.
|
Returns the number of threads used by OpenCV.
|
||||||
|
|
||||||
.. ocv:function:: int getNumThreads()
|
.. ocv:function:: int getNumThreads()
|
||||||
@ -318,7 +326,7 @@ The function returns the number of threads that is used by OpenCV.
|
|||||||
|
|
||||||
|
|
||||||
getThreadNum
|
getThreadNum
|
||||||
----------------
|
------------
|
||||||
Returns the index of the currently executed thread.
|
Returns the index of the currently executed thread.
|
||||||
|
|
||||||
.. ocv:function:: int getThreadNum()
|
.. ocv:function:: int getThreadNum()
|
||||||
@ -332,7 +340,7 @@ The function returns a 0-based index of the currently executed thread. The funct
|
|||||||
|
|
||||||
|
|
||||||
getTickCount
|
getTickCount
|
||||||
----------------
|
------------
|
||||||
Returns the number of ticks.
|
Returns the number of ticks.
|
||||||
|
|
||||||
.. ocv:function:: int64 getTickCount()
|
.. ocv:function:: int64 getTickCount()
|
||||||
@ -346,7 +354,7 @@ It can be used to initialize
|
|||||||
|
|
||||||
|
|
||||||
getTickFrequency
|
getTickFrequency
|
||||||
--------------------
|
----------------
|
||||||
Returns the number of ticks per second.
|
Returns the number of ticks per second.
|
||||||
|
|
||||||
.. ocv:function:: double getTickFrequency()
|
.. ocv:function:: double getTickFrequency()
|
||||||
@ -363,7 +371,7 @@ That is, the following code computes the execution time in seconds: ::
|
|||||||
|
|
||||||
|
|
||||||
getCPUTickCount
|
getCPUTickCount
|
||||||
----------------
|
---------------
|
||||||
Returns the number of CPU ticks.
|
Returns the number of CPU ticks.
|
||||||
|
|
||||||
.. ocv:function:: int64 getCPUTickCount()
|
.. ocv:function:: int64 getCPUTickCount()
|
||||||
@ -417,7 +425,7 @@ The function sets the number of threads used by OpenCV in parallel OpenMP region
|
|||||||
|
|
||||||
|
|
||||||
setUseOptimized
|
setUseOptimized
|
||||||
-----------------
|
---------------
|
||||||
Enables or disables the optimized code.
|
Enables or disables the optimized code.
|
||||||
|
|
||||||
.. ocv:function:: int cvUseOptimized( int on_off )
|
.. ocv:function:: int cvUseOptimized( int on_off )
|
||||||
@ -433,7 +441,7 @@ The function can be used to dynamically turn on and off optimized code (code tha
|
|||||||
By default, the optimized code is enabled unless you disable it in CMake. The current status can be retrieved using ``useOptimized``.
|
By default, the optimized code is enabled unless you disable it in CMake. The current status can be retrieved using ``useOptimized``.
|
||||||
|
|
||||||
useOptimized
|
useOptimized
|
||||||
-----------------
|
------------
|
||||||
Returns the status of optimized code usage.
|
Returns the status of optimized code usage.
|
||||||
|
|
||||||
.. ocv:function:: bool useOptimized()
|
.. ocv:function:: bool useOptimized()
|
||||||
|
@ -3,6 +3,7 @@ package org.opencv.android;
|
|||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.util.StringTokenizer;
|
import java.util.StringTokenizer;
|
||||||
|
|
||||||
|
import org.opencv.core.Core;
|
||||||
import org.opencv.engine.OpenCVEngineInterface;
|
import org.opencv.engine.OpenCVEngineInterface;
|
||||||
|
|
||||||
import android.content.ComponentName;
|
import android.content.ComponentName;
|
||||||
@ -85,7 +86,6 @@ class AsyncServiceHelper
|
|||||||
{
|
{
|
||||||
mServiceInstallationProgress = true;
|
mServiceInstallationProgress = true;
|
||||||
Log.d(TAG, "Package installation started");
|
Log.d(TAG, "Package installation started");
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -299,6 +299,10 @@ class AsyncServiceHelper
|
|||||||
if (initOpenCVLibs(path, libs))
|
if (initOpenCVLibs(path, libs))
|
||||||
{
|
{
|
||||||
Log.d(TAG, "First attempt to load libs is OK");
|
Log.d(TAG, "First attempt to load libs is OK");
|
||||||
|
String eol = System.getProperty("line.separator");
|
||||||
|
for (String str : Core.getBuildInformation().split(eol))
|
||||||
|
Log.i(TAG, str);
|
||||||
|
|
||||||
status = LoaderCallbackInterface.SUCCESS;
|
status = LoaderCallbackInterface.SUCCESS;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -1,7 +1,8 @@
|
|||||||
package org.opencv.android;
|
package org.opencv.android;
|
||||||
|
|
||||||
import java.util.StringTokenizer;
|
import org.opencv.core.Core;
|
||||||
|
|
||||||
|
import java.util.StringTokenizer;
|
||||||
import android.util.Log;
|
import android.util.Log;
|
||||||
|
|
||||||
class StaticHelper {
|
class StaticHelper {
|
||||||
@ -28,6 +29,10 @@ class StaticHelper {
|
|||||||
if (initOpenCVLibs(libs))
|
if (initOpenCVLibs(libs))
|
||||||
{
|
{
|
||||||
Log.d(TAG, "First attempt to load libs is OK");
|
Log.d(TAG, "First attempt to load libs is OK");
|
||||||
|
String eol = System.getProperty("line.separator");
|
||||||
|
for (String str : Core.getBuildInformation().split(eol))
|
||||||
|
Log.i(TAG, str);
|
||||||
|
|
||||||
result = true;
|
result = true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
Loading…
Reference in New Issue
Block a user