21 |
22 | $searchbox
23 |
24 |
25 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/doc/performance.md:
--------------------------------------------------------------------------------
1 | # Performance
2 |
3 | The old performance article for RapidJSON 0.1 is provided [here](https://code.google.com/p/rapidjson/wiki/Performance).
4 |
5 | This file will be updated with new version and better procedures.
6 |
7 | In the meantime, you may also refer to the following third-party benchmarks.
8 |
9 | ## Third-party benchmarks
10 |
11 | * [Basic benchmarks for miscellaneous C++ JSON parsers and generators](https://github.com/mloskot/json_benchmark) by Mateusz Loskot (Jun 2013)
12 | * [casablanca](https://casablanca.codeplex.com/)
13 | * [json_spirit](https://github.com/cierelabs/json_spirit)
14 | * [jsoncpp](http://jsoncpp.sourceforge.net/)
15 | * [libjson](http://sourceforge.net/projects/libjson/)
16 | * [rapidjson](https://github.com/miloyip/rapidjson/)
17 | * [QJsonDocument](http://qt-project.org/doc/qt-5.0/qtcore/qjsondocument.html)
18 |
19 | * [JSON Parser Benchmarking](http://chadaustin.me/2013/01/json-parser-benchmarking/) by Chad Austin (Jan 2013)
20 | * [sajson](https://github.com/chadaustin/sajson)
21 | * [rapidjson](https://github.com/miloyip/rapidjson/)
22 | * [vjson](https://code.google.com/p/vjson/)
23 | * [YAJL](http://lloyd.github.com/yajl/)
24 | * [Jansson](http://www.digip.org/jansson/)
25 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/example/condense/condense.cpp:
--------------------------------------------------------------------------------
1 | // JSON condenser exmaple
2 |
3 | // This example parses JSON text from stdin with validation,
4 | // and re-output the JSON content to stdout without whitespace.
5 |
6 | #include "rapidjson/reader.h"
7 | #include "rapidjson/writer.h"
8 | #include "rapidjson/filereadstream.h"
9 | #include "rapidjson/filewritestream.h"
10 | #include "rapidjson/error/en.h"
11 |
12 | using namespace rapidjson;
13 |
14 | int main(int, char*[]) {
15 | // Prepare JSON reader and input stream.
16 | Reader reader;
17 | char readBuffer[65536];
18 | FileReadStream is(stdin, readBuffer, sizeof(readBuffer));
19 |
20 | // Prepare JSON writer and output stream.
21 | char writeBuffer[65536];
22 | FileWriteStream os(stdout, writeBuffer, sizeof(writeBuffer));
23 | Writer
writer(os);
24 |
25 | // JSON reader parse from the input stream and let writer generate the output.
26 | if (!reader.Parse(is, writer)) {
27 | fprintf(stderr, "\nError(%u): %s\n", (unsigned)reader.GetErrorOffset(), GetParseError_En(reader.GetParseErrorCode()));
28 | return 1;
29 | }
30 |
31 | return 0;
32 | }
33 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/example/pretty/pretty.cpp:
--------------------------------------------------------------------------------
1 | // JSON pretty formatting example
2 | // This example can only handle UTF-8. For handling other encodings, see prettyauto example.
3 |
4 | #include "rapidjson/reader.h"
5 | #include "rapidjson/prettywriter.h"
6 | #include "rapidjson/filereadstream.h"
7 | #include "rapidjson/filewritestream.h"
8 | #include "rapidjson/error/en.h"
9 |
10 | using namespace rapidjson;
11 |
12 | int main(int, char*[]) {
13 | // Prepare reader and input stream.
14 | Reader reader;
15 | char readBuffer[65536];
16 | FileReadStream is(stdin, readBuffer, sizeof(readBuffer));
17 |
18 | // Prepare writer and output stream.
19 | char writeBuffer[65536];
20 | FileWriteStream os(stdout, writeBuffer, sizeof(writeBuffer));
21 | PrettyWriter writer(os);
22 |
23 | // JSON reader parse from the input stream and let writer generate the output.
24 | if (!reader.Parse(is, writer)) {
25 | fprintf(stderr, "\nError(%u): %s\n", (unsigned)reader.GetErrorOffset(), GetParseError_En(reader.GetParseErrorCode()));
26 | return 1;
27 | }
28 |
29 | return 0;
30 | }
31 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/example/simpledom/simpledom.cpp:
--------------------------------------------------------------------------------
1 | // JSON simple example
2 | // This example does not handle errors.
3 |
4 | #include "rapidjson/document.h"
5 | #include "rapidjson/writer.h"
6 | #include "rapidjson/stringbuffer.h"
7 | #include
8 |
9 | using namespace rapidjson;
10 |
11 | int main() {
12 | // 1. Parse a JSON string into DOM.
13 | const char* json = "{\"project\":\"rapidjson\",\"stars\":10}";
14 | Document d;
15 | d.Parse(json);
16 |
17 | // 2. Modify it by DOM.
18 | Value& s = d["stars"];
19 | s.SetInt(s.GetInt() + 1);
20 |
21 | // 3. Stringify the DOM
22 | StringBuffer buffer;
23 | Writer writer(buffer);
24 | d.Accept(writer);
25 |
26 | // Output {"project":"rapidjson","stars":11}
27 | std::cout << buffer.GetString() << std::endl;
28 | return 0;
29 | }
30 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/example/simplewriter/simplewriter.cpp:
--------------------------------------------------------------------------------
1 | #include "rapidjson/writer.h"
2 | #include "rapidjson/stringbuffer.h"
3 | #include
4 |
5 | using namespace rapidjson;
6 | using namespace std;
7 |
8 | int main() {
9 | StringBuffer s;
10 | Writer writer(s);
11 |
12 | writer.StartObject();
13 | writer.String("hello");
14 | writer.String("world");
15 | writer.String("t");
16 | writer.Bool(true);
17 | writer.String("f");
18 | writer.Bool(false);
19 | writer.String("n");
20 | writer.Null();
21 | writer.String("i");
22 | writer.Uint(123);
23 | writer.String("pi");
24 | writer.Double(3.1416);
25 | writer.String("a");
26 | writer.StartArray();
27 | for (unsigned i = 0; i < 4; i++)
28 | writer.Uint(i);
29 | writer.EndArray();
30 | writer.EndObject();
31 |
32 | cout << s.GetString() << endl;
33 |
34 | return 0;
35 | }
36 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/license.txt:
--------------------------------------------------------------------------------
1 | Copyright (C) 2011 Milo Yip
2 |
3 | Permission is hereby granted, free of charge, to any person obtaining a copy
4 | of this software and associated documentation files (the "Software"), to deal
5 | in the Software without restriction, including without limitation the rights
6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 | copies of the Software, and to permit persons to whom the Software is
8 | furnished to do so, subject to the following conditions:
9 |
10 | The above copyright notice and this permission notice shall be included in
11 | all copies or substantial portions of the Software.
12 |
13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19 | THE SOFTWARE.
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/test/perftest/yajl_all.c:
--------------------------------------------------------------------------------
1 | #include "perftest.h"
2 |
3 | #if TEST_YAJL
4 |
5 | #ifdef _MSC_VER
6 | #include
7 | #define isinf !_finite
8 | #define isnan _isnan
9 | #define snprintf _snprintf
10 | #endif
11 |
12 | #include "yajl/src/yajl.c"
13 | #include "yajl/src/yajl_alloc.c"
14 | #include "yajl/src/yajl_buf.c"
15 | #include "yajl/src/yajl_encode.c"
16 | #include "yajl/src/yajl_gen.c"
17 | #include "yajl/src/yajl_lex.c"
18 | #include "yajl/src/yajl_parser.c"
19 | #include "yajl/src/yajl_tree.c"
20 | #include "yajl/src/yajl_version.c"
21 |
22 | #endif // TEST_YAJL
23 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/jsoncpp/AUTHORS:
--------------------------------------------------------------------------------
1 | Baptiste Lepilleur
2 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/jsoncpp/LICENSE:
--------------------------------------------------------------------------------
1 | The json-cpp library and this documentation are in Public Domain.
2 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/jsoncpp/include/json/autolink.h:
--------------------------------------------------------------------------------
1 | #ifndef JSON_AUTOLINK_H_INCLUDED
2 | # define JSON_AUTOLINK_H_INCLUDED
3 |
4 | # include "config.h"
5 |
6 | # ifdef JSON_IN_CPPTL
7 | # include
8 | # endif
9 |
10 | # if !defined(JSON_NO_AUTOLINK) && !defined(JSON_DLL_BUILD) && !defined(JSON_IN_CPPTL)
11 | # define CPPTL_AUTOLINK_NAME "json"
12 | # undef CPPTL_AUTOLINK_DLL
13 | # ifdef JSON_DLL
14 | # define CPPTL_AUTOLINK_DLL
15 | # endif
16 | # include "autolink.h"
17 | # endif
18 |
19 | #endif // JSON_AUTOLINK_H_INCLUDED
20 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/jsoncpp/include/json/forwards.h:
--------------------------------------------------------------------------------
1 | #ifndef JSON_FORWARDS_H_INCLUDED
2 | # define JSON_FORWARDS_H_INCLUDED
3 |
4 | # include "config.h"
5 |
6 | namespace Json {
7 |
8 | // writer.h
9 | class FastWriter;
10 | class StyledWriter;
11 |
12 | // reader.h
13 | class Reader;
14 |
15 | // features.h
16 | class Features;
17 |
18 | // value.h
19 | typedef int Int;
20 | typedef unsigned int UInt;
21 | class StaticString;
22 | class Path;
23 | class PathArgument;
24 | class Value;
25 | class ValueIteratorBase;
26 | class ValueIterator;
27 | class ValueConstIterator;
28 | #ifdef JSON_VALUE_USE_INTERNAL_MAP
29 | class ValueAllocator;
30 | class ValueMapAllocator;
31 | class ValueInternalLink;
32 | class ValueInternalArray;
33 | class ValueInternalMap;
34 | #endif // #ifdef JSON_VALUE_USE_INTERNAL_MAP
35 |
36 | } // namespace Json
37 |
38 |
39 | #endif // JSON_FORWARDS_H_INCLUDED
40 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/jsoncpp/include/json/json.h:
--------------------------------------------------------------------------------
1 | #ifndef JSON_JSON_H_INCLUDED
2 | # define JSON_JSON_H_INCLUDED
3 |
4 | # include "autolink.h"
5 | # include "value.h"
6 | # include "reader.h"
7 | # include "writer.h"
8 | # include "features.h"
9 |
10 | #endif // JSON_JSON_H_INCLUDED
11 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/jsoncpp/src/jsontestrunner/sconscript:
--------------------------------------------------------------------------------
1 | Import( 'env_testing buildJSONTests' )
2 |
3 | buildJSONTests( env_testing, Split( """
4 | main.cpp
5 | """ ),
6 | 'jsontestrunner' )
7 |
8 | # For 'check' to work, 'libs' must be built first.
9 | env_testing.Depends('jsontestrunner', '#libs')
10 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/jsoncpp/src/lib_json/sconscript:
--------------------------------------------------------------------------------
1 | Import( 'env buildLibrary' )
2 |
3 | buildLibrary( env, Split( """
4 | json_reader.cpp
5 | json_value.cpp
6 | json_writer.cpp
7 | """ ),
8 | 'json' )
9 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/jsoncpp/src/test_lib_json/sconscript:
--------------------------------------------------------------------------------
1 | Import( 'env_testing buildUnitTests' )
2 |
3 | buildUnitTests( env_testing, Split( """
4 | main.cpp
5 | jsontest.cpp
6 | """ ),
7 | 'test_lib_json' )
8 |
9 | # For 'check' to work, 'libs' must be built first.
10 | env_testing.Depends('test_lib_json', '#libs')
11 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/jsoncpp/version:
--------------------------------------------------------------------------------
1 | 0.5.0
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/yajl/COPYING:
--------------------------------------------------------------------------------
1 | Copyright (c) 2007-2011, Lloyd Hilaiel
2 |
3 | Permission to use, copy, modify, and/or distribute this software for any
4 | purpose with or without fee is hereby granted, provided that the above
5 | copyright notice and this permission notice appear in all copies.
6 |
7 | THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
8 | WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
9 | MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
10 | ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
11 | WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
12 | ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
13 | OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/yajl/TODO:
--------------------------------------------------------------------------------
1 | * add a test for 0x1F bug
2 | * numeric overflow in integers and double
3 | * line and char offsets in the lexer and in error messages
4 | * testing:
5 | a. the permuter
6 | b. some performance comparison against json_checker.
7 | * investigate pull instead of push parsing
8 | * Handle memory allocation failures gracefully
9 | * cygwin/msys support on win32
10 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/yajl/include/yajl/yajl_version.h:
--------------------------------------------------------------------------------
1 | #ifndef YAJL_VERSION_H_
2 | #define YAJL_VERSION_H_
3 |
4 | #include
5 |
6 | #define YAJL_MAJOR 2
7 | #define YAJL_MINOR 0
8 | #define YAJL_MICRO 1
9 |
10 | #define YAJL_VERSION ((YAJL_MAJOR * 10000) + (YAJL_MINOR * 100) + YAJL_MICRO)
11 |
12 | #ifdef __cplusplus
13 | extern "C" {
14 | #endif
15 |
16 | extern int YAJL_API yajl_version(void);
17 |
18 | #ifdef __cplusplus
19 | }
20 | #endif
21 |
22 | #endif /* YAJL_VERSION_H_ */
23 |
24 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/yajl/src/api/yajl_version.h.cmake:
--------------------------------------------------------------------------------
1 | #ifndef YAJL_VERSION_H_
2 | #define YAJL_VERSION_H_
3 |
4 | #include
5 |
6 | #define YAJL_MAJOR ${YAJL_MAJOR}
7 | #define YAJL_MINOR ${YAJL_MINOR}
8 | #define YAJL_MICRO ${YAJL_MICRO}
9 |
10 | #define YAJL_VERSION ((YAJL_MAJOR * 10000) + (YAJL_MINOR * 100) + YAJL_MICRO)
11 |
12 | #ifdef __cplusplus
13 | extern "C" {
14 | #endif
15 |
16 | extern int YAJL_API yajl_version(void);
17 |
18 | #ifdef __cplusplus
19 | }
20 | #endif
21 |
22 | #endif /* YAJL_VERSION_H_ */
23 |
24 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/yajl/src/yajl:
--------------------------------------------------------------------------------
1 | /**
2 | \example reformatter/json_reformat.c
3 | \example example/parse_config.c
4 | */
5 |
6 | /*!
7 | \mainpage Yet Another JSON Library (YAJL)
8 | \author Lloyd Hilaiel
9 | \date 2007-2011
10 |
11 | Yet Another JSON Library (YAJL) is a small event-driven (SAX-style)
12 | JSON parser written in ANSI C, and a small validating JSON
13 | generator. YAJL is released under the permissive ISC license.
14 |
15 | \section features Features
16 |
17 | -# Stream (incremental) parsing and generation of JSON
18 | -# ANSI C
19 | -# Human readable error messages with context
20 | -# tiny
21 | -# event driven
22 | -# support for generating "beautified" JSON
23 | -# includes
24 | It also includes a small simplified tree interface for
25 | simplified parsing and extraction of data from smallish JSON documents.
26 |
27 | \section usage Usage
28 |
29 | See json_reformat.c for a complete example of stream based parsing
30 | and generation of JSON. See parse_config.c for an example of the
31 | simplified tree interface.
32 |
33 | */
34 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/jni/rapidjson/thirdparty/yajl/src/yajl_version.c:
--------------------------------------------------------------------------------
1 | #include
2 |
3 | int yajl_version(void)
4 | {
5 | return YAJL_VERSION;
6 | }
7 |
8 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/shiyinghan/UVCAndroid/04197e835fa68422b59ab4d2deb26578cdf027e5/libuvccamera/src/main/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/libuvccamera/src/main/res/values-ja/strings_permissions.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | アクセス許可について
4 |
5 | 録音許可がありません。\n音声機能を使用できません。
6 | 音声付きで録画するには録音許可が必要です。
7 |
8 | 外部ストレージへの書き込み許可がありません。静止画・動画保存できません。
9 | 静止画・動画を保存するには外部ストレージへの書き込み許可が必要です。
10 |
11 | ネットワークへのアクセス許可がありません。
12 | ストリーミングを行うにはネットワークへのアクセス許可が必要です。
13 |
14 | 内蔵カメラへのアクセス許可がありません。
15 | 内蔵カメラへのアクセス許可が必要です
16 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/res/values-zh/strings_permissions.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | 关于权限
4 |
5 | 没有录音许可。 \n所有音频功能被禁用
6 | 录制带有录音的视频需要录音权限。
7 |
8 | 没有外部存储的写入权限。 无法保存图像/视频。
9 | 保存图像和视频需要外部存储的写入权限。
10 |
11 | 没有访问网络的权限。
12 | 需要获得访问网络的权限才能进行流式传输。
13 |
14 | 没有访问摄像头的权限。
15 | 需要相机访问权限才能调用外部UVC设备。
16 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/res/values/ids_view_animation.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/libuvccamera/src/main/res/values/strings_permissions.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | Regarding permission
4 |
5 | No audio recording permission. \nAll audio function is disabled
6 | Audio recording permission is necessary for movie capture with audio.
7 |
8 | No permission of writing external storage. \nMovie/still image capturing are disabled.
9 | Permission of writing external storage is necessary for movie/still image capturing.
10 |
11 | No network access permission.
12 | Network access permission is necessary for streaming.
13 |
14 | No camera access permission
15 | Camera access permission is necessary for fallback to built in camera.
16 |
--------------------------------------------------------------------------------
/settings.gradle:
--------------------------------------------------------------------------------
1 | /*
2 | * UVCCamera
3 | * library and sample to access to UVC web camera on non-rooted Android device
4 | *
5 | * Copyright (c) 2014-2017 saki t_saki@serenegiant.com
6 | *
7 | * Licensed under the Apache License, Version 2.0 (the "License");
8 | * you may not use this file except in compliance with the License.
9 | * You may obtain a copy of the License at
10 | *
11 | * http://www.apache.org/licenses/LICENSE-2.0
12 | *
13 | * Unless required by applicable law or agreed to in writing, software
14 | * distributed under the License is distributed on an "AS IS" BASIS,
15 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 | * See the License for the specific language governing permissions and
17 | * limitations under the License.
18 | *
19 | * All files in the folder are under this Apache License, Version 2.0.
20 | * Files in the libjpeg-turbo, libusb, libuvc, rapidjson folder
21 | * may have a different license, see the respective files.
22 | */
23 |
24 | include ':libuvccamera'
25 | include ':app'
26 | include ':demo'
27 |
--------------------------------------------------------------------------------