Preparing to rebase
@@ -1,12 +0,0 @@
|
||||
#http://www.cmake.org/cmake/help/cmake2.6docs.html
|
||||
cmake_minimum_required (VERSION 2.6)
|
||||
project (OpenGL_Qt_Binding)
|
||||
|
||||
|
||||
FIND_PACKAGE( OpenCV REQUIRED )
|
||||
find_package (OpenGL REQUIRED)
|
||||
|
||||
|
||||
ADD_EXECUTABLE(OpenGL_Qt_Binding main.cpp)
|
||||
TARGET_LINK_LIBRARIES(OpenGL_Qt_Binding ${OpenCV_LIBS} ${OPENGL_LIBRARIES} )
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/cube4.avi ${CMAKE_CURRENT_BINARY_DIR}/cube4.avi COPYONLY)
|
Before Width: | Height: | Size: 176 KiB |
Before Width: | Height: | Size: 119 KiB |
Before Width: | Height: | Size: 78 KiB |
Before Width: | Height: | Size: 29 KiB |
Before Width: | Height: | Size: 32 KiB |
Before Width: | Height: | Size: 38 KiB |
Before Width: | Height: | Size: 31 KiB |
Before Width: | Height: | Size: 29 KiB |
Before Width: | Height: | Size: 30 KiB |
Before Width: | Height: | Size: 34 KiB |
Before Width: | Height: | Size: 36 KiB |
Before Width: | Height: | Size: 31 KiB |
Before Width: | Height: | Size: 30 KiB |
@@ -1,400 +0,0 @@
|
||||
/path/to/at/s13/2.pgm;12
|
||||
/path/to/at/s13/7.pgm;12
|
||||
/path/to/at/s13/6.pgm;12
|
||||
/path/to/at/s13/9.pgm;12
|
||||
/path/to/at/s13/5.pgm;12
|
||||
/path/to/at/s13/3.pgm;12
|
||||
/path/to/at/s13/4.pgm;12
|
||||
/path/to/at/s13/10.pgm;12
|
||||
/path/to/at/s13/8.pgm;12
|
||||
/path/to/at/s13/1.pgm;12
|
||||
/path/to/at/s17/2.pgm;16
|
||||
/path/to/at/s17/7.pgm;16
|
||||
/path/to/at/s17/6.pgm;16
|
||||
/path/to/at/s17/9.pgm;16
|
||||
/path/to/at/s17/5.pgm;16
|
||||
/path/to/at/s17/3.pgm;16
|
||||
/path/to/at/s17/4.pgm;16
|
||||
/path/to/at/s17/10.pgm;16
|
||||
/path/to/at/s17/8.pgm;16
|
||||
/path/to/at/s17/1.pgm;16
|
||||
/path/to/at/s32/2.pgm;31
|
||||
/path/to/at/s32/7.pgm;31
|
||||
/path/to/at/s32/6.pgm;31
|
||||
/path/to/at/s32/9.pgm;31
|
||||
/path/to/at/s32/5.pgm;31
|
||||
/path/to/at/s32/3.pgm;31
|
||||
/path/to/at/s32/4.pgm;31
|
||||
/path/to/at/s32/10.pgm;31
|
||||
/path/to/at/s32/8.pgm;31
|
||||
/path/to/at/s32/1.pgm;31
|
||||
/path/to/at/s10/2.pgm;9
|
||||
/path/to/at/s10/7.pgm;9
|
||||
/path/to/at/s10/6.pgm;9
|
||||
/path/to/at/s10/9.pgm;9
|
||||
/path/to/at/s10/5.pgm;9
|
||||
/path/to/at/s10/3.pgm;9
|
||||
/path/to/at/s10/4.pgm;9
|
||||
/path/to/at/s10/10.pgm;9
|
||||
/path/to/at/s10/8.pgm;9
|
||||
/path/to/at/s10/1.pgm;9
|
||||
/path/to/at/s27/2.pgm;26
|
||||
/path/to/at/s27/7.pgm;26
|
||||
/path/to/at/s27/6.pgm;26
|
||||
/path/to/at/s27/9.pgm;26
|
||||
/path/to/at/s27/5.pgm;26
|
||||
/path/to/at/s27/3.pgm;26
|
||||
/path/to/at/s27/4.pgm;26
|
||||
/path/to/at/s27/10.pgm;26
|
||||
/path/to/at/s27/8.pgm;26
|
||||
/path/to/at/s27/1.pgm;26
|
||||
/path/to/at/s5/2.pgm;4
|
||||
/path/to/at/s5/7.pgm;4
|
||||
/path/to/at/s5/6.pgm;4
|
||||
/path/to/at/s5/9.pgm;4
|
||||
/path/to/at/s5/5.pgm;4
|
||||
/path/to/at/s5/3.pgm;4
|
||||
/path/to/at/s5/4.pgm;4
|
||||
/path/to/at/s5/10.pgm;4
|
||||
/path/to/at/s5/8.pgm;4
|
||||
/path/to/at/s5/1.pgm;4
|
||||
/path/to/at/s20/2.pgm;19
|
||||
/path/to/at/s20/7.pgm;19
|
||||
/path/to/at/s20/6.pgm;19
|
||||
/path/to/at/s20/9.pgm;19
|
||||
/path/to/at/s20/5.pgm;19
|
||||
/path/to/at/s20/3.pgm;19
|
||||
/path/to/at/s20/4.pgm;19
|
||||
/path/to/at/s20/10.pgm;19
|
||||
/path/to/at/s20/8.pgm;19
|
||||
/path/to/at/s20/1.pgm;19
|
||||
/path/to/at/s30/2.pgm;29
|
||||
/path/to/at/s30/7.pgm;29
|
||||
/path/to/at/s30/6.pgm;29
|
||||
/path/to/at/s30/9.pgm;29
|
||||
/path/to/at/s30/5.pgm;29
|
||||
/path/to/at/s30/3.pgm;29
|
||||
/path/to/at/s30/4.pgm;29
|
||||
/path/to/at/s30/10.pgm;29
|
||||
/path/to/at/s30/8.pgm;29
|
||||
/path/to/at/s30/1.pgm;29
|
||||
/path/to/at/s39/2.pgm;38
|
||||
/path/to/at/s39/7.pgm;38
|
||||
/path/to/at/s39/6.pgm;38
|
||||
/path/to/at/s39/9.pgm;38
|
||||
/path/to/at/s39/5.pgm;38
|
||||
/path/to/at/s39/3.pgm;38
|
||||
/path/to/at/s39/4.pgm;38
|
||||
/path/to/at/s39/10.pgm;38
|
||||
/path/to/at/s39/8.pgm;38
|
||||
/path/to/at/s39/1.pgm;38
|
||||
/path/to/at/s35/2.pgm;34
|
||||
/path/to/at/s35/7.pgm;34
|
||||
/path/to/at/s35/6.pgm;34
|
||||
/path/to/at/s35/9.pgm;34
|
||||
/path/to/at/s35/5.pgm;34
|
||||
/path/to/at/s35/3.pgm;34
|
||||
/path/to/at/s35/4.pgm;34
|
||||
/path/to/at/s35/10.pgm;34
|
||||
/path/to/at/s35/8.pgm;34
|
||||
/path/to/at/s35/1.pgm;34
|
||||
/path/to/at/s23/2.pgm;22
|
||||
/path/to/at/s23/7.pgm;22
|
||||
/path/to/at/s23/6.pgm;22
|
||||
/path/to/at/s23/9.pgm;22
|
||||
/path/to/at/s23/5.pgm;22
|
||||
/path/to/at/s23/3.pgm;22
|
||||
/path/to/at/s23/4.pgm;22
|
||||
/path/to/at/s23/10.pgm;22
|
||||
/path/to/at/s23/8.pgm;22
|
||||
/path/to/at/s23/1.pgm;22
|
||||
/path/to/at/s4/2.pgm;3
|
||||
/path/to/at/s4/7.pgm;3
|
||||
/path/to/at/s4/6.pgm;3
|
||||
/path/to/at/s4/9.pgm;3
|
||||
/path/to/at/s4/5.pgm;3
|
||||
/path/to/at/s4/3.pgm;3
|
||||
/path/to/at/s4/4.pgm;3
|
||||
/path/to/at/s4/10.pgm;3
|
||||
/path/to/at/s4/8.pgm;3
|
||||
/path/to/at/s4/1.pgm;3
|
||||
/path/to/at/s9/2.pgm;8
|
||||
/path/to/at/s9/7.pgm;8
|
||||
/path/to/at/s9/6.pgm;8
|
||||
/path/to/at/s9/9.pgm;8
|
||||
/path/to/at/s9/5.pgm;8
|
||||
/path/to/at/s9/3.pgm;8
|
||||
/path/to/at/s9/4.pgm;8
|
||||
/path/to/at/s9/10.pgm;8
|
||||
/path/to/at/s9/8.pgm;8
|
||||
/path/to/at/s9/1.pgm;8
|
||||
/path/to/at/s37/2.pgm;36
|
||||
/path/to/at/s37/7.pgm;36
|
||||
/path/to/at/s37/6.pgm;36
|
||||
/path/to/at/s37/9.pgm;36
|
||||
/path/to/at/s37/5.pgm;36
|
||||
/path/to/at/s37/3.pgm;36
|
||||
/path/to/at/s37/4.pgm;36
|
||||
/path/to/at/s37/10.pgm;36
|
||||
/path/to/at/s37/8.pgm;36
|
||||
/path/to/at/s37/1.pgm;36
|
||||
/path/to/at/s24/2.pgm;23
|
||||
/path/to/at/s24/7.pgm;23
|
||||
/path/to/at/s24/6.pgm;23
|
||||
/path/to/at/s24/9.pgm;23
|
||||
/path/to/at/s24/5.pgm;23
|
||||
/path/to/at/s24/3.pgm;23
|
||||
/path/to/at/s24/4.pgm;23
|
||||
/path/to/at/s24/10.pgm;23
|
||||
/path/to/at/s24/8.pgm;23
|
||||
/path/to/at/s24/1.pgm;23
|
||||
/path/to/at/s19/2.pgm;18
|
||||
/path/to/at/s19/7.pgm;18
|
||||
/path/to/at/s19/6.pgm;18
|
||||
/path/to/at/s19/9.pgm;18
|
||||
/path/to/at/s19/5.pgm;18
|
||||
/path/to/at/s19/3.pgm;18
|
||||
/path/to/at/s19/4.pgm;18
|
||||
/path/to/at/s19/10.pgm;18
|
||||
/path/to/at/s19/8.pgm;18
|
||||
/path/to/at/s19/1.pgm;18
|
||||
/path/to/at/s8/2.pgm;7
|
||||
/path/to/at/s8/7.pgm;7
|
||||
/path/to/at/s8/6.pgm;7
|
||||
/path/to/at/s8/9.pgm;7
|
||||
/path/to/at/s8/5.pgm;7
|
||||
/path/to/at/s8/3.pgm;7
|
||||
/path/to/at/s8/4.pgm;7
|
||||
/path/to/at/s8/10.pgm;7
|
||||
/path/to/at/s8/8.pgm;7
|
||||
/path/to/at/s8/1.pgm;7
|
||||
/path/to/at/s21/2.pgm;20
|
||||
/path/to/at/s21/7.pgm;20
|
||||
/path/to/at/s21/6.pgm;20
|
||||
/path/to/at/s21/9.pgm;20
|
||||
/path/to/at/s21/5.pgm;20
|
||||
/path/to/at/s21/3.pgm;20
|
||||
/path/to/at/s21/4.pgm;20
|
||||
/path/to/at/s21/10.pgm;20
|
||||
/path/to/at/s21/8.pgm;20
|
||||
/path/to/at/s21/1.pgm;20
|
||||
/path/to/at/s1/2.pgm;0
|
||||
/path/to/at/s1/7.pgm;0
|
||||
/path/to/at/s1/6.pgm;0
|
||||
/path/to/at/s1/9.pgm;0
|
||||
/path/to/at/s1/5.pgm;0
|
||||
/path/to/at/s1/3.pgm;0
|
||||
/path/to/at/s1/4.pgm;0
|
||||
/path/to/at/s1/10.pgm;0
|
||||
/path/to/at/s1/8.pgm;0
|
||||
/path/to/at/s1/1.pgm;0
|
||||
/path/to/at/s7/2.pgm;6
|
||||
/path/to/at/s7/7.pgm;6
|
||||
/path/to/at/s7/6.pgm;6
|
||||
/path/to/at/s7/9.pgm;6
|
||||
/path/to/at/s7/5.pgm;6
|
||||
/path/to/at/s7/3.pgm;6
|
||||
/path/to/at/s7/4.pgm;6
|
||||
/path/to/at/s7/10.pgm;6
|
||||
/path/to/at/s7/8.pgm;6
|
||||
/path/to/at/s7/1.pgm;6
|
||||
/path/to/at/s16/2.pgm;15
|
||||
/path/to/at/s16/7.pgm;15
|
||||
/path/to/at/s16/6.pgm;15
|
||||
/path/to/at/s16/9.pgm;15
|
||||
/path/to/at/s16/5.pgm;15
|
||||
/path/to/at/s16/3.pgm;15
|
||||
/path/to/at/s16/4.pgm;15
|
||||
/path/to/at/s16/10.pgm;15
|
||||
/path/to/at/s16/8.pgm;15
|
||||
/path/to/at/s16/1.pgm;15
|
||||
/path/to/at/s36/2.pgm;35
|
||||
/path/to/at/s36/7.pgm;35
|
||||
/path/to/at/s36/6.pgm;35
|
||||
/path/to/at/s36/9.pgm;35
|
||||
/path/to/at/s36/5.pgm;35
|
||||
/path/to/at/s36/3.pgm;35
|
||||
/path/to/at/s36/4.pgm;35
|
||||
/path/to/at/s36/10.pgm;35
|
||||
/path/to/at/s36/8.pgm;35
|
||||
/path/to/at/s36/1.pgm;35
|
||||
/path/to/at/s25/2.pgm;24
|
||||
/path/to/at/s25/7.pgm;24
|
||||
/path/to/at/s25/6.pgm;24
|
||||
/path/to/at/s25/9.pgm;24
|
||||
/path/to/at/s25/5.pgm;24
|
||||
/path/to/at/s25/3.pgm;24
|
||||
/path/to/at/s25/4.pgm;24
|
||||
/path/to/at/s25/10.pgm;24
|
||||
/path/to/at/s25/8.pgm;24
|
||||
/path/to/at/s25/1.pgm;24
|
||||
/path/to/at/s14/2.pgm;13
|
||||
/path/to/at/s14/7.pgm;13
|
||||
/path/to/at/s14/6.pgm;13
|
||||
/path/to/at/s14/9.pgm;13
|
||||
/path/to/at/s14/5.pgm;13
|
||||
/path/to/at/s14/3.pgm;13
|
||||
/path/to/at/s14/4.pgm;13
|
||||
/path/to/at/s14/10.pgm;13
|
||||
/path/to/at/s14/8.pgm;13
|
||||
/path/to/at/s14/1.pgm;13
|
||||
/path/to/at/s34/2.pgm;33
|
||||
/path/to/at/s34/7.pgm;33
|
||||
/path/to/at/s34/6.pgm;33
|
||||
/path/to/at/s34/9.pgm;33
|
||||
/path/to/at/s34/5.pgm;33
|
||||
/path/to/at/s34/3.pgm;33
|
||||
/path/to/at/s34/4.pgm;33
|
||||
/path/to/at/s34/10.pgm;33
|
||||
/path/to/at/s34/8.pgm;33
|
||||
/path/to/at/s34/1.pgm;33
|
||||
/path/to/at/s11/2.pgm;10
|
||||
/path/to/at/s11/7.pgm;10
|
||||
/path/to/at/s11/6.pgm;10
|
||||
/path/to/at/s11/9.pgm;10
|
||||
/path/to/at/s11/5.pgm;10
|
||||
/path/to/at/s11/3.pgm;10
|
||||
/path/to/at/s11/4.pgm;10
|
||||
/path/to/at/s11/10.pgm;10
|
||||
/path/to/at/s11/8.pgm;10
|
||||
/path/to/at/s11/1.pgm;10
|
||||
/path/to/at/s26/2.pgm;25
|
||||
/path/to/at/s26/7.pgm;25
|
||||
/path/to/at/s26/6.pgm;25
|
||||
/path/to/at/s26/9.pgm;25
|
||||
/path/to/at/s26/5.pgm;25
|
||||
/path/to/at/s26/3.pgm;25
|
||||
/path/to/at/s26/4.pgm;25
|
||||
/path/to/at/s26/10.pgm;25
|
||||
/path/to/at/s26/8.pgm;25
|
||||
/path/to/at/s26/1.pgm;25
|
||||
/path/to/at/s18/2.pgm;17
|
||||
/path/to/at/s18/7.pgm;17
|
||||
/path/to/at/s18/6.pgm;17
|
||||
/path/to/at/s18/9.pgm;17
|
||||
/path/to/at/s18/5.pgm;17
|
||||
/path/to/at/s18/3.pgm;17
|
||||
/path/to/at/s18/4.pgm;17
|
||||
/path/to/at/s18/10.pgm;17
|
||||
/path/to/at/s18/8.pgm;17
|
||||
/path/to/at/s18/1.pgm;17
|
||||
/path/to/at/s29/2.pgm;28
|
||||
/path/to/at/s29/7.pgm;28
|
||||
/path/to/at/s29/6.pgm;28
|
||||
/path/to/at/s29/9.pgm;28
|
||||
/path/to/at/s29/5.pgm;28
|
||||
/path/to/at/s29/3.pgm;28
|
||||
/path/to/at/s29/4.pgm;28
|
||||
/path/to/at/s29/10.pgm;28
|
||||
/path/to/at/s29/8.pgm;28
|
||||
/path/to/at/s29/1.pgm;28
|
||||
/path/to/at/s33/2.pgm;32
|
||||
/path/to/at/s33/7.pgm;32
|
||||
/path/to/at/s33/6.pgm;32
|
||||
/path/to/at/s33/9.pgm;32
|
||||
/path/to/at/s33/5.pgm;32
|
||||
/path/to/at/s33/3.pgm;32
|
||||
/path/to/at/s33/4.pgm;32
|
||||
/path/to/at/s33/10.pgm;32
|
||||
/path/to/at/s33/8.pgm;32
|
||||
/path/to/at/s33/1.pgm;32
|
||||
/path/to/at/s12/2.pgm;11
|
||||
/path/to/at/s12/7.pgm;11
|
||||
/path/to/at/s12/6.pgm;11
|
||||
/path/to/at/s12/9.pgm;11
|
||||
/path/to/at/s12/5.pgm;11
|
||||
/path/to/at/s12/3.pgm;11
|
||||
/path/to/at/s12/4.pgm;11
|
||||
/path/to/at/s12/10.pgm;11
|
||||
/path/to/at/s12/8.pgm;11
|
||||
/path/to/at/s12/1.pgm;11
|
||||
/path/to/at/s6/2.pgm;5
|
||||
/path/to/at/s6/7.pgm;5
|
||||
/path/to/at/s6/6.pgm;5
|
||||
/path/to/at/s6/9.pgm;5
|
||||
/path/to/at/s6/5.pgm;5
|
||||
/path/to/at/s6/3.pgm;5
|
||||
/path/to/at/s6/4.pgm;5
|
||||
/path/to/at/s6/10.pgm;5
|
||||
/path/to/at/s6/8.pgm;5
|
||||
/path/to/at/s6/1.pgm;5
|
||||
/path/to/at/s22/2.pgm;21
|
||||
/path/to/at/s22/7.pgm;21
|
||||
/path/to/at/s22/6.pgm;21
|
||||
/path/to/at/s22/9.pgm;21
|
||||
/path/to/at/s22/5.pgm;21
|
||||
/path/to/at/s22/3.pgm;21
|
||||
/path/to/at/s22/4.pgm;21
|
||||
/path/to/at/s22/10.pgm;21
|
||||
/path/to/at/s22/8.pgm;21
|
||||
/path/to/at/s22/1.pgm;21
|
||||
/path/to/at/s15/2.pgm;14
|
||||
/path/to/at/s15/7.pgm;14
|
||||
/path/to/at/s15/6.pgm;14
|
||||
/path/to/at/s15/9.pgm;14
|
||||
/path/to/at/s15/5.pgm;14
|
||||
/path/to/at/s15/3.pgm;14
|
||||
/path/to/at/s15/4.pgm;14
|
||||
/path/to/at/s15/10.pgm;14
|
||||
/path/to/at/s15/8.pgm;14
|
||||
/path/to/at/s15/1.pgm;14
|
||||
/path/to/at/s2/2.pgm;1
|
||||
/path/to/at/s2/7.pgm;1
|
||||
/path/to/at/s2/6.pgm;1
|
||||
/path/to/at/s2/9.pgm;1
|
||||
/path/to/at/s2/5.pgm;1
|
||||
/path/to/at/s2/3.pgm;1
|
||||
/path/to/at/s2/4.pgm;1
|
||||
/path/to/at/s2/10.pgm;1
|
||||
/path/to/at/s2/8.pgm;1
|
||||
/path/to/at/s2/1.pgm;1
|
||||
/path/to/at/s31/2.pgm;30
|
||||
/path/to/at/s31/7.pgm;30
|
||||
/path/to/at/s31/6.pgm;30
|
||||
/path/to/at/s31/9.pgm;30
|
||||
/path/to/at/s31/5.pgm;30
|
||||
/path/to/at/s31/3.pgm;30
|
||||
/path/to/at/s31/4.pgm;30
|
||||
/path/to/at/s31/10.pgm;30
|
||||
/path/to/at/s31/8.pgm;30
|
||||
/path/to/at/s31/1.pgm;30
|
||||
/path/to/at/s28/2.pgm;27
|
||||
/path/to/at/s28/7.pgm;27
|
||||
/path/to/at/s28/6.pgm;27
|
||||
/path/to/at/s28/9.pgm;27
|
||||
/path/to/at/s28/5.pgm;27
|
||||
/path/to/at/s28/3.pgm;27
|
||||
/path/to/at/s28/4.pgm;27
|
||||
/path/to/at/s28/10.pgm;27
|
||||
/path/to/at/s28/8.pgm;27
|
||||
/path/to/at/s28/1.pgm;27
|
||||
/path/to/at/s40/2.pgm;39
|
||||
/path/to/at/s40/7.pgm;39
|
||||
/path/to/at/s40/6.pgm;39
|
||||
/path/to/at/s40/9.pgm;39
|
||||
/path/to/at/s40/5.pgm;39
|
||||
/path/to/at/s40/3.pgm;39
|
||||
/path/to/at/s40/4.pgm;39
|
||||
/path/to/at/s40/10.pgm;39
|
||||
/path/to/at/s40/8.pgm;39
|
||||
/path/to/at/s40/1.pgm;39
|
||||
/path/to/at/s3/2.pgm;2
|
||||
/path/to/at/s3/7.pgm;2
|
||||
/path/to/at/s3/6.pgm;2
|
||||
/path/to/at/s3/9.pgm;2
|
||||
/path/to/at/s3/5.pgm;2
|
||||
/path/to/at/s3/3.pgm;2
|
||||
/path/to/at/s3/4.pgm;2
|
||||
/path/to/at/s3/10.pgm;2
|
||||
/path/to/at/s3/8.pgm;2
|
||||
/path/to/at/s3/1.pgm;2
|
||||
/path/to/at/s38/2.pgm;37
|
||||
/path/to/at/s38/7.pgm;37
|
||||
/path/to/at/s38/6.pgm;37
|
||||
/path/to/at/s38/9.pgm;37
|
||||
/path/to/at/s38/5.pgm;37
|
||||
/path/to/at/s38/3.pgm;37
|
||||
/path/to/at/s38/4.pgm;37
|
||||
/path/to/at/s38/10.pgm;37
|
||||
/path/to/at/s38/8.pgm;37
|
||||
/path/to/at/s38/1.pgm;37
|
@@ -1,10 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<opencv_storage>
|
||||
<nclasses>0</nclasses>
|
||||
<patchSize>31</patchSize>
|
||||
<signatureSize>INT_MAX</signatureSize>
|
||||
<nstructs>50</nstructs>
|
||||
<structSize>9</structSize>
|
||||
<nviews>1000</nviews>
|
||||
<compressionMethod>0</compressionMethod>
|
||||
</opencv_storage>
|
@@ -1,186 +0,0 @@
|
||||
/*
|
||||
* filestorage_sample demonstrate the usage of the opencv serialization functionality
|
||||
*/
|
||||
|
||||
#include "opencv2/core/core.hpp"
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
|
||||
using std::string;
|
||||
using std::cout;
|
||||
using std::endl;
|
||||
using std::cerr;
|
||||
using std::ostream;
|
||||
using namespace cv;
|
||||
|
||||
static void help(char** av)
|
||||
{
|
||||
cout << "\nfilestorage_sample demonstrate the usage of the opencv serialization functionality.\n"
|
||||
<< "usage:\n"
|
||||
<< av[0] << " outputfile.yml.gz\n"
|
||||
<< "\n outputfile above can have many different extenstions, see below."
|
||||
<< "\nThis program demonstrates the use of FileStorage for serialization, that is use << and >> in OpenCV\n"
|
||||
<< "For example, how to create a class and have it serialize, but also how to use it to read and write matrices.\n"
|
||||
<< "FileStorage allows you to serialize to various formats specified by the file end type."
|
||||
<< "\nYou should try using different file extensions.(e.g. yaml yml xml xml.gz yaml.gz etc...)\n" << endl;
|
||||
}
|
||||
|
||||
struct MyData
|
||||
{
|
||||
MyData() :
|
||||
A(0), X(0), id()
|
||||
{
|
||||
}
|
||||
explicit MyData(int) :
|
||||
A(97), X(CV_PI), id("mydata1234")
|
||||
{
|
||||
}
|
||||
int A;
|
||||
double X;
|
||||
string id;
|
||||
void write(FileStorage& fs) const //Write serialization for this class
|
||||
{
|
||||
fs << "{" << "A" << A << "X" << X << "id" << id << "}";
|
||||
}
|
||||
void read(const FileNode& node) //Read serialization for this class
|
||||
{
|
||||
|
||||
A = (int)node["A"];
|
||||
X = (double)node["X"];
|
||||
id = (string)node["id"];
|
||||
}
|
||||
};
|
||||
|
||||
//These write and read functions must exist as per the inline functions in operations.hpp
|
||||
static void write(FileStorage& fs, const std::string&, const MyData& x){
|
||||
x.write(fs);
|
||||
}
|
||||
static void read(const FileNode& node, MyData& x, const MyData& default_value = MyData()){
|
||||
if(node.empty())
|
||||
x = default_value;
|
||||
else
|
||||
x.read(node);
|
||||
}
|
||||
|
||||
static ostream& operator<<(ostream& out, const MyData& m){
|
||||
out << "{ id = " << m.id << ", ";
|
||||
out << "X = " << m.X << ", ";
|
||||
out << "A = " << m.A << "}";
|
||||
return out;
|
||||
}
|
||||
int main(int ac, char** av)
|
||||
{
|
||||
if (ac != 2)
|
||||
{
|
||||
help(av);
|
||||
return 1;
|
||||
}
|
||||
|
||||
string filename = av[1];
|
||||
|
||||
//write
|
||||
{
|
||||
FileStorage fs(filename, FileStorage::WRITE);
|
||||
|
||||
cout << "writing images\n";
|
||||
fs << "images" << "[";
|
||||
|
||||
fs << "image1.jpg" << "myfi.png" << "baboon.jpg";
|
||||
cout << "image1.jpg" << " myfi.png" << " baboon.jpg" << endl;
|
||||
|
||||
fs << "]";
|
||||
|
||||
cout << "writing mats\n";
|
||||
Mat R =Mat_<double>::eye(3, 3),T = Mat_<double>::zeros(3, 1);
|
||||
cout << "R = " << R << "\n";
|
||||
cout << "T = " << T << "\n";
|
||||
fs << "R" << R;
|
||||
fs << "T" << T;
|
||||
|
||||
cout << "writing MyData struct\n";
|
||||
MyData m(1);
|
||||
fs << "mdata" << m;
|
||||
cout << m << endl;
|
||||
}
|
||||
|
||||
//read
|
||||
{
|
||||
FileStorage fs(filename, FileStorage::READ);
|
||||
|
||||
if (!fs.isOpened())
|
||||
{
|
||||
cerr << "failed to open " << filename << endl;
|
||||
help(av);
|
||||
return 1;
|
||||
}
|
||||
|
||||
FileNode n = fs["images"];
|
||||
if (n.type() != FileNode::SEQ)
|
||||
{
|
||||
cerr << "images is not a sequence! FAIL" << endl;
|
||||
return 1;
|
||||
}
|
||||
|
||||
cout << "reading images\n";
|
||||
FileNodeIterator it = n.begin(), it_end = n.end();
|
||||
for (; it != it_end; ++it)
|
||||
{
|
||||
cout << (string)*it << "\n";
|
||||
}
|
||||
|
||||
Mat R, T;
|
||||
cout << "reading R and T" << endl;
|
||||
|
||||
fs["R"] >> R;
|
||||
fs["T"] >> T;
|
||||
|
||||
cout << "R = " << R << "\n";
|
||||
cout << "T = " << T << endl;
|
||||
|
||||
MyData m;
|
||||
fs["mdata"] >> m;
|
||||
|
||||
cout << "read mdata\n";
|
||||
cout << m << endl;
|
||||
|
||||
cout << "attempting to read mdata_b\n"; //Show default behavior for empty matrix
|
||||
fs["mdata_b"] >> m;
|
||||
cout << "read mdata_b\n";
|
||||
cout << m << endl;
|
||||
|
||||
}
|
||||
|
||||
cout << "Try opening " << filename << " to see the serialized data." << endl << endl;
|
||||
|
||||
//read from string
|
||||
{
|
||||
cout << "Read data from string\n";
|
||||
string dataString =
|
||||
"%YAML:1.0\n"
|
||||
"mdata:\n"
|
||||
" A: 97\n"
|
||||
" X: 3.1415926535897931e+00\n"
|
||||
" id: mydata1234\n";
|
||||
MyData m;
|
||||
FileStorage fs(dataString, FileStorage::READ | FileStorage::MEMORY);
|
||||
cout << "attempting to read mdata_b from string\n"; //Show default behavior for empty matrix
|
||||
fs["mdata"] >> m;
|
||||
cout << "read mdata\n";
|
||||
cout << m << endl;
|
||||
}
|
||||
|
||||
//write to string
|
||||
{
|
||||
cout << "Write data to string\n";
|
||||
FileStorage fs(filename, FileStorage::WRITE | FileStorage::MEMORY | FileStorage::FORMAT_YAML);
|
||||
|
||||
cout << "writing MyData struct\n";
|
||||
MyData m(1);
|
||||
fs << "mdata" << m;
|
||||
cout << m << endl;
|
||||
string createdString = fs.releaseAndGetString();
|
||||
cout << "Created string:\n" << createdString << "\n";
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
Before Width: | Height: | Size: 80 KiB |
@@ -1,36 +0,0 @@
|
||||
#include "opencv2/imgproc/imgproc.hpp"
|
||||
#include "opencv2/contrib/contrib.hpp"
|
||||
#include "opencv2/highgui/highgui.hpp"
|
||||
|
||||
#include <cstdio>
|
||||
#include <iostream>
|
||||
#include <ctime>
|
||||
|
||||
using namespace cv;
|
||||
using namespace std;
|
||||
|
||||
int main(int argc, char** argv)
|
||||
{
|
||||
if( argc != 2 )
|
||||
{
|
||||
cout << "Colors count should be passed." << endl;
|
||||
return -1;
|
||||
}
|
||||
|
||||
int colorsCount = atoi(argv[1]);
|
||||
vector<Scalar> colors;
|
||||
theRNG() = (uint64)time(0);
|
||||
generateColors( colors, colorsCount );
|
||||
|
||||
int stripWidth = 20;
|
||||
Mat strips(300, colorsCount*stripWidth, CV_8UC3);
|
||||
for( int i = 0; i < colorsCount; i++ )
|
||||
{
|
||||
strips.colRange(i*stripWidth, (i+1)*stripWidth) = colors[i];
|
||||
}
|
||||
|
||||
imshow( "strips", strips );
|
||||
waitKey();
|
||||
|
||||
return 0;
|
||||
}
|
@@ -1,47 +0,0 @@
|
||||
/*this creates a yaml or xml list of files from the command line args
|
||||
*/
|
||||
|
||||
#include "opencv2/core/core.hpp"
|
||||
#include "opencv2/highgui/highgui.hpp"
|
||||
#include <string>
|
||||
#include <iostream>
|
||||
|
||||
using std::string;
|
||||
using std::cout;
|
||||
using std::endl;
|
||||
|
||||
using namespace cv;
|
||||
|
||||
static void help(char** av)
|
||||
{
|
||||
cout << "\nThis creates a yaml or xml list of files from the command line args\n"
|
||||
"usage:\n./" << av[0] << " imagelist.yaml *.png\n"
|
||||
<< "Try using different extensions.(e.g. yaml yml xml xml.gz etc...)\n"
|
||||
<< "This will serialize this list of images or whatever with opencv's FileStorage framework" << endl;
|
||||
}
|
||||
|
||||
int main(int ac, char** av)
|
||||
{
|
||||
if (ac < 3)
|
||||
{
|
||||
help(av);
|
||||
return 1;
|
||||
}
|
||||
|
||||
string outputname = av[1];
|
||||
|
||||
Mat m = imread(outputname); //check if the output is an image - prevent overwrites!
|
||||
if(!m.empty()){
|
||||
std::cerr << "fail! Please specify an output file, don't want to overwrite you images!" << endl;
|
||||
help(av);
|
||||
return 1;
|
||||
}
|
||||
|
||||
FileStorage fs(outputname, FileStorage::WRITE);
|
||||
fs << "images" << "[";
|
||||
for(int i = 2; i < ac; i++){
|
||||
fs << string(av[i]);
|
||||
}
|
||||
fs << "]";
|
||||
return 0;
|
||||
}
|
Before Width: | Height: | Size: 27 KiB |
Before Width: | Height: | Size: 28 KiB |
Before Width: | Height: | Size: 29 KiB |
Before Width: | Height: | Size: 25 KiB |
Before Width: | Height: | Size: 28 KiB |
Before Width: | Height: | Size: 28 KiB |
Before Width: | Height: | Size: 29 KiB |
Before Width: | Height: | Size: 28 KiB |
Before Width: | Height: | Size: 27 KiB |
Before Width: | Height: | Size: 27 KiB |
Before Width: | Height: | Size: 25 KiB |
Before Width: | Height: | Size: 28 KiB |
Before Width: | Height: | Size: 27 KiB |
Before Width: | Height: | Size: 90 KiB |
Before Width: | Height: | Size: 939 B |
Before Width: | Height: | Size: 94 KiB |
Before Width: | Height: | Size: 119 KiB |
Before Width: | Height: | Size: 116 KiB |
Before Width: | Height: | Size: 112 KiB |
Before Width: | Height: | Size: 118 KiB |
@@ -1,3 +0,0 @@
|
||||
1.png
|
||||
2.png
|
||||
3.png
|
Before Width: | Height: | Size: 13 KiB |
Before Width: | Height: | Size: 254 KiB |
Before Width: | Height: | Size: 25 KiB |
Before Width: | Height: | Size: 108 KiB |
Before Width: | Height: | Size: 15 KiB |
Before Width: | Height: | Size: 16 KiB |
Before Width: | Height: | Size: 102 KiB |
Before Width: | Height: | Size: 100 KiB |
Before Width: | Height: | Size: 455 KiB |
Before Width: | Height: | Size: 433 KiB |
Before Width: | Height: | Size: 26 KiB |
Before Width: | Height: | Size: 27 KiB |
Before Width: | Height: | Size: 28 KiB |
Before Width: | Height: | Size: 24 KiB |
Before Width: | Height: | Size: 26 KiB |
Before Width: | Height: | Size: 27 KiB |
Before Width: | Height: | Size: 28 KiB |
Before Width: | Height: | Size: 28 KiB |
Before Width: | Height: | Size: 25 KiB |
Before Width: | Height: | Size: 25 KiB |
Before Width: | Height: | Size: 24 KiB |
Before Width: | Height: | Size: 27 KiB |
Before Width: | Height: | Size: 25 KiB |
@@ -1,32 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<opencv_storage>
|
||||
<imagelist>
|
||||
"left01.jpg"
|
||||
"right01.jpg"
|
||||
"left02.jpg"
|
||||
"right02.jpg"
|
||||
"left03.jpg"
|
||||
"right03.jpg"
|
||||
"left04.jpg"
|
||||
"right04.jpg"
|
||||
"left05.jpg"
|
||||
"right05.jpg"
|
||||
"left06.jpg"
|
||||
"right06.jpg"
|
||||
"left07.jpg"
|
||||
"right07.jpg"
|
||||
"left08.jpg"
|
||||
"right08.jpg"
|
||||
"left09.jpg"
|
||||
"right09.jpg"
|
||||
"left11.jpg"
|
||||
"right11.jpg"
|
||||
"left12.jpg"
|
||||
"right12.jpg"
|
||||
"left13.jpg"
|
||||
"right13.jpg"
|
||||
"left14.jpg"
|
||||
"right14.jpg"
|
||||
</imagelist>
|
||||
</opencv_storage>
|
||||
|
Before Width: | Height: | Size: 29 KiB |
Before Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 83 KiB |
Before Width: | Height: | Size: 83 KiB |
@@ -1,69 +0,0 @@
|
||||
/**
|
||||
* @file LinearBlend.cpp
|
||||
* @brief Simple linear blender ( dst = alpha*src1 + beta*src2 )
|
||||
* @author OpenCV team
|
||||
*/
|
||||
|
||||
#include "opencv2/highgui/highgui.hpp"
|
||||
#include <stdio.h>
|
||||
|
||||
using namespace cv;
|
||||
|
||||
/** Global Variables */
|
||||
const int alpha_slider_max = 100;
|
||||
int alpha_slider;
|
||||
double alpha;
|
||||
double beta;
|
||||
|
||||
/** Matrices to store images */
|
||||
Mat src1;
|
||||
Mat src2;
|
||||
Mat dst;
|
||||
|
||||
/**
|
||||
* @function on_trackbar
|
||||
* @brief Callback for trackbar
|
||||
*/
|
||||
static void on_trackbar( int, void* )
|
||||
{
|
||||
alpha = (double) alpha_slider/alpha_slider_max ;
|
||||
|
||||
beta = ( 1.0 - alpha );
|
||||
|
||||
addWeighted( src1, alpha, src2, beta, 0.0, dst);
|
||||
|
||||
imshow( "Linear Blend", dst );
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @function main
|
||||
* @brief Main function
|
||||
*/
|
||||
int main( void )
|
||||
{
|
||||
/// Read image ( same size, same type )
|
||||
src1 = imread("../images/LinuxLogo.jpg");
|
||||
src2 = imread("../images/WindowsLogo.jpg");
|
||||
|
||||
if( !src1.data ) { printf("Error loading src1 \n"); return -1; }
|
||||
if( !src2.data ) { printf("Error loading src2 \n"); return -1; }
|
||||
|
||||
/// Initialize values
|
||||
alpha_slider = 0;
|
||||
|
||||
/// Create Windows
|
||||
namedWindow("Linear Blend", 1);
|
||||
|
||||
/// Create Trackbars
|
||||
char TrackbarName[50];
|
||||
sprintf( TrackbarName, "Alpha x %d", alpha_slider_max );
|
||||
createTrackbar( TrackbarName, "Linear Blend", &alpha_slider, alpha_slider_max, on_trackbar );
|
||||
|
||||
/// Show some stuff
|
||||
on_trackbar( alpha_slider, 0 );
|
||||
|
||||
/// Wait until user press some key
|
||||
waitKey(0);
|
||||
return 0;
|
||||
}
|
@@ -1,69 +0,0 @@
|
||||
/**
|
||||
* @file LinearTransforms.cpp
|
||||
* @brief Simple program to change contrast and brightness
|
||||
* @date Mon, June 6, 2011
|
||||
* @author OpenCV team
|
||||
*/
|
||||
|
||||
#include "opencv2/highgui/highgui.hpp"
|
||||
|
||||
using namespace cv;
|
||||
|
||||
/** Global Variables */
|
||||
const int alpha_max = 5;
|
||||
const int beta_max = 125;
|
||||
int alpha; /**< Simple contrast control */
|
||||
int beta; /**< Simple brightness control*/
|
||||
|
||||
/** Matrices to store images */
|
||||
Mat image;
|
||||
|
||||
/**
|
||||
* @function on_trackbar
|
||||
* @brief Called whenever any of alpha or beta changes
|
||||
*/
|
||||
static void on_trackbar( int, void* )
|
||||
{
|
||||
Mat new_image = Mat::zeros( image.size(), image.type() );
|
||||
|
||||
for( int y = 0; y < image.rows; y++ )
|
||||
{ for( int x = 0; x < image.cols; x++ )
|
||||
{ for( int c = 0; c < 3; c++ )
|
||||
{
|
||||
new_image.at<Vec3b>(y,x)[c] = saturate_cast<uchar>( alpha*( image.at<Vec3b>(y,x)[c] ) + beta );
|
||||
}
|
||||
}
|
||||
}
|
||||
imshow("New Image", new_image);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @function main
|
||||
* @brief Main function
|
||||
*/
|
||||
int main( int, char** argv )
|
||||
{
|
||||
/// Read image given by user
|
||||
image = imread( argv[1] );
|
||||
|
||||
/// Initialize values
|
||||
alpha = 1;
|
||||
beta = 0;
|
||||
|
||||
/// Create Windows
|
||||
namedWindow("Original Image", 1);
|
||||
namedWindow("New Image", 1);
|
||||
|
||||
/// Create Trackbars
|
||||
createTrackbar( "Contrast Trackbar", "New Image", &alpha, alpha_max, on_trackbar );
|
||||
createTrackbar( "Brightness Trackbar", "New Image", &beta, beta_max, on_trackbar );
|
||||
|
||||
/// Show some stuff
|
||||
imshow("Original Image", image);
|
||||
imshow("New Image", image);
|
||||
|
||||
/// Wait until user press some key
|
||||
waitKey();
|
||||
return 0;
|
||||
}
|
@@ -1,51 +0,0 @@
|
||||
/**
|
||||
* @file AddingImages.cpp
|
||||
* @brief Simple linear blender ( dst = alpha*src1 + beta*src2 )
|
||||
* @author OpenCV team
|
||||
*/
|
||||
|
||||
#include "opencv2/highgui/highgui.hpp"
|
||||
#include <iostream>
|
||||
|
||||
using namespace cv;
|
||||
|
||||
/**
|
||||
* @function main
|
||||
* @brief Main function
|
||||
*/
|
||||
int main( void )
|
||||
{
|
||||
|
||||
double alpha = 0.5; double beta; double input;
|
||||
|
||||
Mat src1, src2, dst;
|
||||
|
||||
/// Ask the user enter alpha
|
||||
std::cout<<" Simple Linear Blender "<<std::endl;
|
||||
std::cout<<"-----------------------"<<std::endl;
|
||||
std::cout<<"* Enter alpha [0-1]: ";
|
||||
std::cin>>input;
|
||||
|
||||
// We use the alpha provided by the user iff it is between 0 and 1
|
||||
if( alpha >= 0 && alpha <= 1 )
|
||||
{ alpha = input; }
|
||||
|
||||
/// Read image ( same size, same type )
|
||||
src1 = imread("../images/LinuxLogo.jpg");
|
||||
src2 = imread("../images/WindowsLogo.jpg");
|
||||
|
||||
if( !src1.data ) { std::cout<< "Error loading src1"<<std::endl; return -1; }
|
||||
if( !src2.data ) { std::cout<< "Error loading src2"<<std::endl; return -1; }
|
||||
|
||||
/// Create Windows
|
||||
namedWindow("Linear Blend", 1);
|
||||
|
||||
beta = ( 1.0 - alpha );
|
||||
addWeighted( src1, alpha, src2, beta, 0.0, dst);
|
||||
|
||||
imshow( "Linear Blend", dst );
|
||||
|
||||
|
||||
waitKey(0);
|
||||
return 0;
|
||||
}
|
@@ -1,57 +0,0 @@
|
||||
/**
|
||||
* @file BasicLinearTransforms.cpp
|
||||
* @brief Simple program to change contrast and brightness
|
||||
* @author OpenCV team
|
||||
*/
|
||||
|
||||
#include "opencv2/highgui/highgui.hpp"
|
||||
#include <iostream>
|
||||
|
||||
using namespace cv;
|
||||
|
||||
double alpha; /**< Simple contrast control */
|
||||
int beta; /**< Simple brightness control */
|
||||
|
||||
/**
|
||||
* @function main
|
||||
* @brief Main function
|
||||
*/
|
||||
int main( int, char** argv )
|
||||
{
|
||||
/// Read image given by user
|
||||
Mat image = imread( argv[1] );
|
||||
Mat new_image = Mat::zeros( image.size(), image.type() );
|
||||
|
||||
/// Initialize values
|
||||
std::cout<<" Basic Linear Transforms "<<std::endl;
|
||||
std::cout<<"-------------------------"<<std::endl;
|
||||
std::cout<<"* Enter the alpha value [1.0-3.0]: ";std::cin>>alpha;
|
||||
std::cout<<"* Enter the beta value [0-100]: "; std::cin>>beta;
|
||||
|
||||
|
||||
/// Do the operation new_image(i,j) = alpha*image(i,j) + beta
|
||||
/// Instead of these 'for' loops we could have used simply:
|
||||
/// image.convertTo(new_image, -1, alpha, beta);
|
||||
/// but we wanted to show you how to access the pixels :)
|
||||
for( int y = 0; y < image.rows; y++ )
|
||||
{ for( int x = 0; x < image.cols; x++ )
|
||||
{ for( int c = 0; c < 3; c++ )
|
||||
{
|
||||
new_image.at<Vec3b>(y,x)[c] = saturate_cast<uchar>( alpha*( image.at<Vec3b>(y,x)[c] ) + beta );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Create Windows
|
||||
namedWindow("Original Image", 1);
|
||||
namedWindow("New Image", 1);
|
||||
|
||||
/// Show stuff
|
||||
imshow("Original Image", image);
|
||||
imshow("New Image", new_image);
|
||||
|
||||
|
||||
/// Wait until user press some key
|
||||
waitKey();
|
||||
return 0;
|
||||
}
|
@@ -1,13 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<opencv_storage>
|
||||
<images>
|
||||
images/CameraCalibraation/VID5/xx1.jpg
|
||||
images/CameraCalibraation/VID5/xx2.jpg
|
||||
images/CameraCalibraation/VID5/xx3.jpg
|
||||
images/CameraCalibraation/VID5/xx4.jpg
|
||||
images/CameraCalibraation/VID5/xx5.jpg
|
||||
images/CameraCalibraation/VID5/xx6.jpg
|
||||
images/CameraCalibraation/VID5/xx7.jpg
|
||||
images/CameraCalibraation/VID5/xx8.jpg
|
||||
</images>
|
||||
</opencv_storage>
|
@@ -1,46 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<opencv_storage>
|
||||
<Settings>
|
||||
<!-- Number of inner corners per a item row and column. (square, circle) -->
|
||||
<BoardSize_Width> 9</BoardSize_Width>
|
||||
<BoardSize_Height>6</BoardSize_Height>
|
||||
|
||||
<!-- The size of a square in some user defined metric system (pixel, millimeter)-->
|
||||
<Square_Size>50</Square_Size>
|
||||
|
||||
<!-- The type of input used for camera calibration. One of: CHESSBOARD CIRCLES_GRID ASYMMETRIC_CIRCLES_GRID -->
|
||||
<Calibrate_Pattern>"CHESSBOARD"</Calibrate_Pattern>
|
||||
|
||||
<!-- The input to use for calibration.
|
||||
To use an input camera -> give the ID of the camera, like "1"
|
||||
To use an input video -> give the path of the input video, like "/tmp/x.avi"
|
||||
To use an image list -> give the path to the XML or YAML file containing the list of the images, like "/tmp/circles_list.xml"
|
||||
-->
|
||||
<Input>"images/CameraCalibraation/VID5/VID5.xml"</Input>
|
||||
<!-- If true (non-zero) we flip the input images around the horizontal axis.-->
|
||||
<Input_FlipAroundHorizontalAxis>0</Input_FlipAroundHorizontalAxis>
|
||||
|
||||
<!-- Time delay between frames in case of camera. -->
|
||||
<Input_Delay>100</Input_Delay>
|
||||
|
||||
<!-- How many frames to use, for calibration. -->
|
||||
<Calibrate_NrOfFrameToUse>25</Calibrate_NrOfFrameToUse>
|
||||
<!-- Consider only fy as a free parameter, the ratio fx/fy stays the same as in the input cameraMatrix.
|
||||
Use or not setting. 0 - False Non-Zero - True-->
|
||||
<Calibrate_FixAspectRatio> 1 </Calibrate_FixAspectRatio>
|
||||
<!-- If true (non-zero) tangential distortion coefficients are set to zeros and stay zero.-->
|
||||
<Calibrate_AssumeZeroTangentialDistortion>1</Calibrate_AssumeZeroTangentialDistortion>
|
||||
<!-- If true (non-zero) the principal point is not changed during the global optimization.-->
|
||||
<Calibrate_FixPrincipalPointAtTheCenter> 1 </Calibrate_FixPrincipalPointAtTheCenter>
|
||||
|
||||
<!-- The name of the output log file. -->
|
||||
<Write_outputFileName>"out_camera_data.xml"</Write_outputFileName>
|
||||
<!-- If true (non-zero) we write to the output file the feature points.-->
|
||||
<Write_DetectedFeaturePoints>1</Write_DetectedFeaturePoints>
|
||||
<!-- If true (non-zero) we write to the output file the extrinsic camera parameters.-->
|
||||
<Write_extrinsicParameters>1</Write_extrinsicParameters>
|
||||
<!-- If true (non-zero) we show after calibration the undistorted images.-->
|
||||
<Show_UndistortedImage>1</Show_UndistortedImage>
|
||||
|
||||
</Settings>
|
||||
</opencv_storage>
|
@@ -1,352 +0,0 @@
|
||||
%YAML:1.0
|
||||
calibration_Time: "08/19/11 20:44:38"
|
||||
nrOfFrames: 8
|
||||
image_Width: 640
|
||||
image_Height: 480
|
||||
board_Width: 9
|
||||
board_Height: 6
|
||||
square_Size: 50.
|
||||
FixAspectRatio: 1.
|
||||
# flags: +fix_aspectRatio +fix_principal_point +zero_tangent_dist
|
||||
flagValue: 14
|
||||
Camera_Matrix: !!opencv-matrix
|
||||
rows: 3
|
||||
cols: 3
|
||||
dt: d
|
||||
data: [ 6.5746697810243404e+002, 0., 3.1950000000000000e+002, 0.,
|
||||
6.5746697810243404e+002, 2.3950000000000000e+002, 0., 0., 1. ]
|
||||
Distortion_Coefficients: !!opencv-matrix
|
||||
rows: 5
|
||||
cols: 1
|
||||
dt: d
|
||||
data: [ -4.1802327018241026e-001, 5.0715243805833121e-001, 0., 0.,
|
||||
-5.7843596847939704e-001 ]
|
||||
Avg_Reprojection_Error: 3.8441346462381665e-001
|
||||
Per_View_Reprojection_Errors: !!opencv-matrix
|
||||
rows: 8
|
||||
cols: 1
|
||||
dt: f
|
||||
data: [ 5.04357755e-001, 4.85754758e-001, 3.99563968e-001,
|
||||
4.13829178e-001, 3.53570908e-001, 3.21116358e-001,
|
||||
2.74473161e-001, 2.39761785e-001 ]
|
||||
# a set of 6-tuples (rotation vector + translation vector) for each view
|
||||
Extrinsic_Parameters: !!opencv-matrix
|
||||
rows: 8
|
||||
cols: 6
|
||||
dt: d
|
||||
data: [ -7.8704123655486097e-002, -1.5922384772614945e-001,
|
||||
3.1166227207451498e+000, 2.4224388101960471e+002,
|
||||
1.1795590397660339e+002, 6.2576484126093249e+002,
|
||||
-1.4117480285164308e-001, -1.7917415443804836e-002,
|
||||
3.1333182268743949e+000, 2.5943034781849354e+002,
|
||||
1.4039780562976958e+002, 6.3848706527260981e+002,
|
||||
7.2230525186138789e-002, -7.5445981266787754e-002,
|
||||
1.5712860749221762e+000, 1.7426560451795339e+002,
|
||||
-1.9309240362258871e+002, 7.0891416556762647e+002,
|
||||
2.0367310600105853e-002, 6.8565520026996951e-002,
|
||||
-5.4313033031644169e-004, -2.0146314940404827e+002,
|
||||
-1.3305643514116997e+002, 7.4933554744027231e+002,
|
||||
-3.4468530027734055e-002, 2.1921265175331925e-002,
|
||||
-1.5731053528054522e+000, -1.1155718744299284e+002,
|
||||
2.0307615364261443e+002, 8.4915903914333899e+002,
|
||||
3.7425562109513817e-002, 7.4883169379022230e-002,
|
||||
-3.6031632305130512e-002, -2.0094505419395196e+002,
|
||||
-1.1627359108310560e+002, 9.2021583518760133e+002,
|
||||
6.8105689976949157e-002, 6.4426739692440949e-002,
|
||||
-7.0967130057087435e-002, -1.9233852871740035e+002,
|
||||
-1.0334652096641923e+002, 1.0755293563503658e+003,
|
||||
-5.8017546499862287e-002, -1.6909812666033443e-003,
|
||||
-1.5876137659782963e+000, -1.0242234847115104e+002,
|
||||
2.2583088401423066e+002, 1.1125972190244058e+003 ]
|
||||
Image_points: !!opencv-matrix
|
||||
rows: 8
|
||||
cols: 54
|
||||
dt: "2f"
|
||||
data: [ 5.58494690e+002, 3.55650085e+002, 5.13314697e+002,
|
||||
3.59107666e+002, 4.65728333e+002, 3.62133911e+002,
|
||||
4.15701111e+002, 3.65026459e+002, 3.64399353e+002,
|
||||
3.67339203e+002, 3.12101196e+002, 3.69211914e+002,
|
||||
2.59208405e+002, 3.70413513e+002, 2.07456192e+002,
|
||||
3.71175995e+002, 1.56619507e+002, 3.72176544e+002,
|
||||
5.60868713e+002, 3.08104828e+002, 5.15191772e+002,
|
||||
3.10485626e+002, 4.67032959e+002, 3.12660004e+002,
|
||||
4.16112152e+002, 3.14887177e+002, 3.64010712e+002,
|
||||
3.16825775e+002, 3.10712372e+002, 3.18640808e+002,
|
||||
2.56853943e+002, 3.20017365e+002, 2.04168182e+002,
|
||||
3.20908417e+002, 1.52469528e+002, 3.22105377e+002,
|
||||
5.62328369e+002, 2.58646881e+002, 5.16396301e+002,
|
||||
2.59919281e+002, 4.67907654e+002, 2.61257874e+002,
|
||||
4.16463440e+002, 2.62675537e+002, 3.63546570e+002,
|
||||
2.64064117e+002, 3.09528137e+002, 2.65489990e+002,
|
||||
2.54765533e+002, 2.66862030e+002, 2.01299225e+002,
|
||||
2.67997345e+002, 1.48913437e+002, 2.69627167e+002,
|
||||
5.63098022e+002, 2.08423523e+002, 5.16782654e+002,
|
||||
2.08424667e+002, 4.68059296e+002, 2.08661697e+002,
|
||||
4.16216431e+002, 2.09268982e+002, 3.62888763e+002,
|
||||
2.10013397e+002, 3.08458557e+002, 2.11074738e+002,
|
||||
2.53267990e+002, 2.12496582e+002, 1.99121384e+002,
|
||||
2.14005814e+002, 1.46551376e+002, 2.15851318e+002,
|
||||
5.62997437e+002, 1.57966492e+002, 5.16406494e+002,
|
||||
1.56580688e+002, 4.67334900e+002, 1.55756500e+002,
|
||||
4.15378235e+002, 1.55492874e+002, 3.62096710e+002,
|
||||
1.55498734e+002, 3.07522827e+002, 1.56133240e+002,
|
||||
2.52235214e+002, 1.57516571e+002, 1.97876328e+002,
|
||||
1.59318787e+002, 1.45078247e+002, 1.61638428e+002,
|
||||
5.62097168e+002, 1.07469536e+002, 5.15766846e+002,
|
||||
1.04902527e+002, 4.66562866e+002, 1.03045807e+002,
|
||||
4.14651459e+002, 1.01924713e+002, 3.61240662e+002,
|
||||
1.01357826e+002, 3.06746613e+002, 1.01582802e+002,
|
||||
2.51568024e+002, 1.02920105e+002, 1.97343307e+002,
|
||||
1.04941299e+002, 1.44756821e+002, 1.07737488e+002,
|
||||
5.68062500e+002, 3.73591125e+002, 5.25272644e+002,
|
||||
3.77019318e+002, 4.79870941e+002, 3.80086578e+002,
|
||||
4.31823730e+002, 3.83036652e+002, 3.81995758e+002,
|
||||
3.85271759e+002, 3.30728729e+002, 3.86998779e+002,
|
||||
2.78071167e+002, 3.88151031e+002, 2.26231567e+002,
|
||||
3.88669586e+002, 1.74855331e+002, 3.89197998e+002,
|
||||
5.69792542e+002, 3.27097382e+002, 5.26866028e+002,
|
||||
3.29362366e+002, 4.81278229e+002, 3.31532928e+002,
|
||||
4.32783203e+002, 3.33552185e+002, 3.82408234e+002,
|
||||
3.35186554e+002, 3.30427399e+002, 3.36404053e+002,
|
||||
2.77138519e+002, 3.37450958e+002, 2.24525131e+002,
|
||||
3.37957092e+002, 1.72285507e+002, 3.38503540e+002,
|
||||
5.70942749e+002, 2.79243713e+002, 5.27789307e+002,
|
||||
2.80073486e+002, 4.82146576e+002, 2.81226410e+002,
|
||||
4.33247375e+002, 2.82237427e+002, 3.82503662e+002,
|
||||
2.83062286e+002, 3.30138885e+002, 2.83794434e+002,
|
||||
2.76433228e+002, 2.84549286e+002, 2.23158783e+002,
|
||||
2.84981049e+002, 1.70520218e+002, 2.85720886e+002,
|
||||
5.71001953e+002, 2.30928329e+002, 5.27846863e+002,
|
||||
2.30519928e+002, 4.82114563e+002, 2.30268906e+002,
|
||||
4.33114563e+002, 2.30243515e+002, 3.82384857e+002,
|
||||
2.30311340e+002, 3.29870392e+002, 2.30454620e+002,
|
||||
2.76012634e+002, 2.30882156e+002, 2.22529434e+002,
|
||||
2.31355362e+002, 1.69742065e+002, 2.32063004e+002,
|
||||
5.70199036e+002, 1.82609772e+002, 5.27030884e+002,
|
||||
1.80973267e+002, 4.81193573e+002, 1.79573792e+002,
|
||||
4.32409821e+002, 1.78475616e+002, 3.81855530e+002,
|
||||
1.77680283e+002, 3.29641937e+002, 1.77092087e+002,
|
||||
2.75895782e+002, 1.77155502e+002, 2.22438889e+002,
|
||||
1.77605667e+002, 1.69884583e+002, 1.78365585e+002,
|
||||
5.69026245e+002, 1.34654831e+002, 5.26171570e+002,
|
||||
1.31798691e+002, 4.80653503e+002, 1.29171509e+002,
|
||||
4.31869904e+002, 1.27280067e+002, 3.81419739e+002,
|
||||
1.25591202e+002, 3.29466644e+002, 1.24407089e+002,
|
||||
2.76225342e+002, 1.24174736e+002, 2.23024109e+002,
|
||||
1.24463333e+002, 1.70838898e+002, 1.25398903e+002,
|
||||
4.73812897e+002, 6.94673386e+001, 4.74245453e+002,
|
||||
1.12387466e+002, 4.74243347e+002, 1.56034164e+002,
|
||||
4.73834778e+002, 2.00523651e+002, 4.72891602e+002,
|
||||
2.44457306e+002, 4.71412811e+002, 2.87981171e+002,
|
||||
4.69708252e+002, 3.30783173e+002, 4.67558228e+002,
|
||||
3.71818420e+002, 4.65495667e+002, 4.11996979e+002,
|
||||
4.31027649e+002, 6.75546722e+001, 4.31269440e+002,
|
||||
1.10960022e+002, 4.31185486e+002, 1.55113556e+002,
|
||||
4.30830139e+002, 2.00061066e+002, 4.30168427e+002,
|
||||
2.44456863e+002, 4.29107544e+002, 2.88479645e+002,
|
||||
4.27829071e+002, 3.31813507e+002, 4.26131653e+002,
|
||||
3.73071228e+002, 4.24718811e+002, 4.13476563e+002,
|
||||
3.86868805e+002, 6.61982269e+001, 3.86895416e+002,
|
||||
1.09904411e+002, 3.86690216e+002, 1.54396423e+002,
|
||||
3.86368591e+002, 1.99800369e+002, 3.85792206e+002,
|
||||
2.44538574e+002, 3.85117279e+002, 2.88826447e+002,
|
||||
3.84405273e+002, 3.32408020e+002, 3.83303772e+002,
|
||||
3.74074097e+002, 3.82477448e+002, 4.14638977e+002,
|
||||
3.41941437e+002, 6.54462357e+001, 3.41628204e+002,
|
||||
1.09383698e+002, 3.41402344e+002, 1.54105545e+002,
|
||||
3.41168854e+002, 1.99655045e+002, 3.40816681e+002,
|
||||
2.44469910e+002, 3.40516937e+002, 2.88975800e+002,
|
||||
3.40365662e+002, 3.32670990e+002, 3.39935211e+002,
|
||||
3.74465759e+002, 3.39847626e+002, 4.14742279e+002,
|
||||
2.96694000e+002, 6.56859589e+001, 2.96075226e+002,
|
||||
1.09505333e+002, 2.95704895e+002, 1.54202652e+002,
|
||||
2.95653107e+002, 1.99734131e+002, 2.95589661e+002,
|
||||
2.44549530e+002, 2.95629547e+002, 2.88889496e+002,
|
||||
2.96138733e+002, 3.32610931e+002, 2.96520905e+002,
|
||||
3.74608551e+002, 2.96987091e+002, 4.14774902e+002,
|
||||
2.51414978e+002, 6.65755463e+001, 2.50681854e+002,
|
||||
1.10189331e+002, 2.50183380e+002, 1.54658005e+002,
|
||||
2.50331161e+002, 2.00073761e+002, 2.50590790e+002,
|
||||
2.44719513e+002, 2.51083817e+002, 2.88868286e+002,
|
||||
2.52134262e+002, 3.32266937e+002, 2.53097809e+002,
|
||||
3.74022491e+002, 2.54404007e+002, 4.14018066e+002,
|
||||
1.49524078e+002, 1.27699501e+002, 1.89511658e+002,
|
||||
1.25816605e+002, 2.31050888e+002, 1.24260918e+002,
|
||||
2.74076721e+002, 1.23023209e+002, 3.17643005e+002,
|
||||
1.22288109e+002, 3.61785889e+002, 1.22105164e+002,
|
||||
4.06142670e+002, 1.22401566e+002, 4.49623962e+002,
|
||||
1.23246025e+002, 4.92677216e+002, 1.24087708e+002,
|
||||
1.48706085e+002, 1.69077423e+002, 1.88827805e+002,
|
||||
1.67750443e+002, 2.30439865e+002, 1.66769333e+002,
|
||||
2.73830933e+002, 1.65871170e+002, 3.17596741e+002,
|
||||
1.65410919e+002, 3.61983459e+002, 1.65327866e+002,
|
||||
4.06748322e+002, 1.65463974e+002, 4.50450226e+002,
|
||||
1.66126526e+002, 4.93614655e+002, 1.66970413e+002,
|
||||
1.48312607e+002, 2.11499451e+002, 1.88574097e+002,
|
||||
2.10860214e+002, 2.30130676e+002, 2.10261612e+002,
|
||||
2.73557709e+002, 2.09837143e+002, 3.17542572e+002,
|
||||
2.09633057e+002, 3.62091248e+002, 2.09732620e+002,
|
||||
4.06934570e+002, 2.09926758e+002, 4.50914612e+002,
|
||||
2.10320221e+002, 4.94044495e+002, 2.10900925e+002,
|
||||
1.48613831e+002, 2.53997177e+002, 1.88797791e+002,
|
||||
2.53912842e+002, 2.30240204e+002, 2.53975067e+002,
|
||||
2.73746704e+002, 2.54010208e+002, 3.17718262e+002,
|
||||
2.54106003e+002, 3.62188965e+002, 2.54205475e+002,
|
||||
4.06908783e+002, 2.54317505e+002, 4.50824951e+002,
|
||||
2.54539490e+002, 4.93825714e+002, 2.54753876e+002,
|
||||
1.49541687e+002, 2.96404175e+002, 1.89357727e+002,
|
||||
2.97117523e+002, 2.30807007e+002, 2.97805603e+002,
|
||||
2.74325470e+002, 2.97966522e+002, 3.18042206e+002,
|
||||
2.98304535e+002, 3.62105774e+002, 2.98552643e+002,
|
||||
4.06672272e+002, 2.98572418e+002, 4.50363068e+002,
|
||||
2.98569550e+002, 4.93109894e+002, 2.98516205e+002,
|
||||
1.50883698e+002, 3.38493195e+002, 1.90633621e+002,
|
||||
3.39862610e+002, 2.31920990e+002, 3.40869415e+002,
|
||||
2.74971252e+002, 3.41453766e+002, 3.18235229e+002,
|
||||
3.41952637e+002, 3.62063477e+002, 3.42314026e+002,
|
||||
4.06098938e+002, 3.42221802e+002, 4.49477386e+002,
|
||||
3.42063812e+002, 4.91864716e+002, 3.41727600e+002,
|
||||
2.36129852e+002, 3.92798004e+002, 2.34999939e+002,
|
||||
3.56118683e+002, 2.34376099e+002, 3.18607025e+002,
|
||||
2.33822159e+002, 2.80400696e+002, 2.33565445e+002,
|
||||
2.42213104e+002, 2.33583069e+002, 2.03937286e+002,
|
||||
2.34028824e+002, 1.65756607e+002, 2.34613373e+002,
|
||||
1.28586639e+002, 2.35190308e+002, 9.18279037e+001,
|
||||
2.73031616e+002, 3.93267242e+002, 2.72295166e+002,
|
||||
3.56342743e+002, 2.71799347e+002, 3.18847412e+002,
|
||||
2.71418854e+002, 2.80287872e+002, 2.71161469e+002,
|
||||
2.41881134e+002, 2.71248962e+002, 2.03348145e+002,
|
||||
2.71379303e+002, 1.64895874e+002, 2.71946045e+002,
|
||||
1.27450935e+002, 2.72322418e+002, 9.06900787e+001,
|
||||
3.10670715e+002, 3.93568848e+002, 3.10389160e+002,
|
||||
3.56545959e+002, 3.10084625e+002, 3.18814514e+002,
|
||||
3.09801544e+002, 2.80242737e+002, 3.09678711e+002,
|
||||
2.41574814e+002, 3.09779663e+002, 2.02989838e+002,
|
||||
3.09842712e+002, 1.64338043e+002, 3.10076782e+002,
|
||||
1.26870911e+002, 3.10243286e+002, 8.98413315e+001,
|
||||
3.48618134e+002, 3.93563202e+002, 3.48617065e+002,
|
||||
3.56472382e+002, 3.48608795e+002, 3.18855621e+002,
|
||||
3.48544556e+002, 2.80011017e+002, 3.48556396e+002,
|
||||
2.41388168e+002, 3.48585388e+002, 2.02692429e+002,
|
||||
3.48435089e+002, 1.64099731e+002, 3.48442902e+002,
|
||||
1.26549957e+002, 3.48338043e+002, 8.98002014e+001,
|
||||
3.86625610e+002, 3.93188599e+002, 3.87047729e+002,
|
||||
3.56377594e+002, 3.87306274e+002, 3.18714752e+002,
|
||||
3.87337799e+002, 2.79868896e+002, 3.87402740e+002,
|
||||
2.41228760e+002, 3.87295166e+002, 2.02695313e+002,
|
||||
3.87030273e+002, 1.64203415e+002, 3.86741211e+002,
|
||||
1.26606262e+002, 3.86337311e+002, 8.99655075e+001,
|
||||
4.24534088e+002, 3.92702545e+002, 4.25310822e+002,
|
||||
3.55900452e+002, 4.25869019e+002, 3.18160614e+002,
|
||||
4.25909790e+002, 2.79615753e+002, 4.25977295e+002,
|
||||
2.41165100e+002, 4.25826477e+002, 2.02876389e+002,
|
||||
4.25331665e+002, 1.64527618e+002, 4.24775787e+002,
|
||||
1.27097328e+002, 4.23985138e+002, 9.08176651e+001,
|
||||
1.79142670e+002, 1.58573654e+002, 2.12791580e+002,
|
||||
1.56291031e+002, 2.47140106e+002, 1.54265656e+002,
|
||||
2.82607300e+002, 1.52373688e+002, 3.18175507e+002,
|
||||
1.50692184e+002, 3.54185852e+002, 1.49404175e+002,
|
||||
3.90455200e+002, 1.48229370e+002, 4.26106689e+002,
|
||||
1.47507843e+002, 4.61576141e+002, 1.46712479e+002,
|
||||
1.80388336e+002, 1.93027603e+002, 2.14026459e+002,
|
||||
1.91128204e+002, 2.48376541e+002, 1.89414978e+002,
|
||||
2.83795807e+002, 1.87720856e+002, 3.19472473e+002,
|
||||
1.86192383e+002, 3.55483826e+002, 1.84929199e+002,
|
||||
3.91970764e+002, 1.83747040e+002, 4.27654572e+002,
|
||||
1.82931534e+002, 4.63295227e+002, 1.81977234e+002,
|
||||
1.81914261e+002, 2.27955460e+002, 2.15291260e+002,
|
||||
2.26512482e+002, 2.49628265e+002, 2.25067520e+002,
|
||||
2.85066406e+002, 2.23593185e+002, 3.20846680e+002,
|
||||
2.22337708e+002, 3.56862885e+002, 2.21191040e+002,
|
||||
3.93279907e+002, 2.19905640e+002, 4.29202271e+002,
|
||||
2.18870361e+002, 4.64728424e+002, 2.17972977e+002,
|
||||
1.83496948e+002, 2.62963226e+002, 2.16930527e+002,
|
||||
2.61755219e+002, 2.51115829e+002, 2.60777222e+002,
|
||||
2.86553406e+002, 2.59500336e+002, 3.22299896e+002,
|
||||
2.58380737e+002, 3.58307648e+002, 2.57236694e+002,
|
||||
3.94551819e+002, 2.56009125e+002, 4.30358948e+002,
|
||||
2.54925797e+002, 4.65684998e+002, 2.54021484e+002,
|
||||
1.85461685e+002, 2.97687378e+002, 2.18712234e+002,
|
||||
2.96999207e+002, 2.52770218e+002, 2.96270752e+002,
|
||||
2.88213776e+002, 2.95168213e+002, 3.23698334e+002,
|
||||
2.94233032e+002, 3.59477722e+002, 2.93170715e+002,
|
||||
3.95647766e+002, 2.91897400e+002, 4.31309845e+002,
|
||||
2.90856995e+002, 4.66494110e+002, 2.89726410e+002,
|
||||
1.87661331e+002, 3.32186188e+002, 2.20767746e+002,
|
||||
3.31906250e+002, 2.54839096e+002, 3.31398651e+002,
|
||||
2.89963745e+002, 3.30524139e+002, 3.25207642e+002,
|
||||
3.29771820e+002, 3.60686035e+002, 3.28762695e+002,
|
||||
3.96576447e+002, 3.27542206e+002, 4.31994415e+002,
|
||||
3.26294189e+002, 4.66894653e+002, 3.24949921e+002,
|
||||
2.03543015e+002, 1.77473557e+002, 2.32777847e+002,
|
||||
1.74712509e+002, 2.62628723e+002, 1.72331970e+002,
|
||||
2.93045898e+002, 1.69686768e+002, 3.23527618e+002,
|
||||
1.67496246e+002, 3.54206787e+002, 1.65446075e+002,
|
||||
3.85180176e+002, 1.63360580e+002, 4.15484253e+002,
|
||||
1.61536423e+002, 4.45720947e+002, 1.59896164e+002,
|
||||
2.05864395e+002, 2.07228104e+002, 2.35242096e+002,
|
||||
2.04699326e+002, 2.64853973e+002, 2.02407455e+002,
|
||||
2.95353882e+002, 1.99972321e+002, 3.25811890e+002,
|
||||
1.97671921e+002, 3.56471252e+002, 1.95763168e+002,
|
||||
3.87280548e+002, 1.93597977e+002, 4.17615814e+002,
|
||||
1.91867371e+002, 4.48018677e+002, 1.90067413e+002,
|
||||
2.08421249e+002, 2.37166977e+002, 2.37513824e+002,
|
||||
2.34982773e+002, 2.67261261e+002, 2.32802841e+002,
|
||||
2.97555817e+002, 2.30466080e+002, 3.28118103e+002,
|
||||
2.28462463e+002, 3.58699707e+002, 2.26417038e+002,
|
||||
3.89468842e+002, 2.24356827e+002, 4.19895996e+002,
|
||||
2.22421921e+002, 4.50077850e+002, 2.20683517e+002,
|
||||
2.11095444e+002, 2.66940186e+002, 2.40241348e+002,
|
||||
2.64970093e+002, 2.69563019e+002, 2.63153290e+002,
|
||||
2.99863464e+002, 2.60983551e+002, 3.30282440e+002,
|
||||
2.58911560e+002, 3.60724792e+002, 2.56935730e+002,
|
||||
3.91487915e+002, 2.54799423e+002, 4.21789093e+002,
|
||||
2.52929688e+002, 4.51818481e+002, 2.51059357e+002,
|
||||
2.13829117e+002, 2.96591217e+002, 2.42742859e+002,
|
||||
2.94884583e+002, 2.72209076e+002, 2.93215668e+002,
|
||||
3.02402985e+002, 2.91230591e+002, 3.32536072e+002,
|
||||
2.89165192e+002, 3.62860901e+002, 2.87413605e+002,
|
||||
3.93481842e+002, 2.85199615e+002, 4.23728851e+002,
|
||||
2.83277496e+002, 4.53453094e+002, 2.81229309e+002,
|
||||
2.16799316e+002, 3.25975220e+002, 2.45605515e+002,
|
||||
3.24619904e+002, 2.74777344e+002, 3.22958679e+002,
|
||||
3.04762817e+002, 3.21008057e+002, 3.34797150e+002,
|
||||
3.19291443e+002, 3.65005798e+002, 3.17295044e+002,
|
||||
3.95311981e+002, 3.15296021e+002, 4.25312592e+002,
|
||||
3.13086945e+002, 4.54931152e+002, 3.11027130e+002,
|
||||
2.60550232e+002, 3.70739563e+002, 2.59674011e+002,
|
||||
3.42115936e+002, 2.58910492e+002, 3.13278015e+002,
|
||||
2.58195618e+002, 2.84013580e+002, 2.57727173e+002,
|
||||
2.55017166e+002, 2.57326263e+002, 2.25760986e+002,
|
||||
2.57096619e+002, 1.96577972e+002, 2.57031860e+002,
|
||||
1.68026199e+002, 2.56873383e+002, 1.39550308e+002,
|
||||
2.89019318e+002, 3.70481354e+002, 2.88355560e+002,
|
||||
3.41833252e+002, 2.87601471e+002, 3.12872925e+002,
|
||||
2.87057190e+002, 2.83485535e+002, 2.86599762e+002,
|
||||
2.54255096e+002, 2.86174438e+002, 2.25023285e+002,
|
||||
2.85775940e+002, 1.95715347e+002, 2.85577087e+002,
|
||||
1.66989502e+002, 2.85395477e+002, 1.38597382e+002,
|
||||
3.18072754e+002, 3.70118317e+002, 3.17432709e+002,
|
||||
3.41398743e+002, 3.16917267e+002, 3.12476044e+002,
|
||||
3.16284363e+002, 2.83001587e+002, 3.15799072e+002,
|
||||
2.53725845e+002, 3.15411957e+002, 2.24337708e+002,
|
||||
3.15070374e+002, 1.95034119e+002, 3.14736847e+002,
|
||||
1.66195313e+002, 3.14439789e+002, 1.37797058e+002,
|
||||
3.47083588e+002, 3.69678101e+002, 3.46717987e+002,
|
||||
3.40949524e+002, 3.46185303e+002, 3.12009857e+002,
|
||||
3.45728088e+002, 2.82454071e+002, 3.45226624e+002,
|
||||
2.53109863e+002, 3.44883606e+002, 2.23839539e+002,
|
||||
3.44373535e+002, 1.94399933e+002, 3.43879852e+002,
|
||||
1.65690643e+002, 3.43438629e+002, 1.37252930e+002,
|
||||
3.76341522e+002, 3.68972321e+002, 3.76086884e+002,
|
||||
3.40412842e+002, 3.75708893e+002, 3.11398376e+002,
|
||||
3.75143494e+002, 2.81901520e+002, 3.74762970e+002,
|
||||
2.52577988e+002, 3.74223969e+002, 2.23348221e+002,
|
||||
3.73600891e+002, 1.93979538e+002, 3.72983917e+002,
|
||||
1.65201294e+002, 3.72517273e+002, 1.36871033e+002,
|
||||
4.05512115e+002, 3.68243225e+002, 4.05366333e+002,
|
||||
3.39678650e+002, 4.05090027e+002, 3.10679108e+002,
|
||||
4.04612366e+002, 2.81203522e+002, 4.04152649e+002,
|
||||
2.52051605e+002, 4.03539703e+002, 2.22930420e+002,
|
||||
4.02903351e+002, 1.93625381e+002, 4.02272827e+002,
|
||||
1.65004440e+002, 4.01353333e+002, 1.36796814e+002 ]
|
@@ -1,154 +0,0 @@
|
||||
#include <opencv2/core/core.hpp>
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
|
||||
using namespace cv;
|
||||
using namespace std;
|
||||
|
||||
static void help(char** av)
|
||||
{
|
||||
cout << endl
|
||||
<< av[0] << " shows the usage of the OpenCV serialization functionality." << endl
|
||||
<< "usage: " << endl
|
||||
<< av[0] << " outputfile.yml.gz" << endl
|
||||
<< "The output file may be either XML (xml) or YAML (yml/yaml). You can even compress it by "
|
||||
<< "specifying this in its extension like xml.gz yaml.gz etc... " << endl
|
||||
<< "With FileStorage you can serialize objects in OpenCV by using the << and >> operators" << endl
|
||||
<< "For example: - create a class and have it serialized" << endl
|
||||
<< " - use it to read and write matrices." << endl;
|
||||
}
|
||||
|
||||
class MyData
|
||||
{
|
||||
public:
|
||||
MyData() : A(0), X(0), id()
|
||||
{}
|
||||
explicit MyData(int) : A(97), X(CV_PI), id("mydata1234") // explicit to avoid implicit conversion
|
||||
{}
|
||||
void write(FileStorage& fs) const //Write serialization for this class
|
||||
{
|
||||
fs << "{" << "A" << A << "X" << X << "id" << id << "}";
|
||||
}
|
||||
void read(const FileNode& node) //Read serialization for this class
|
||||
{
|
||||
A = (int)node["A"];
|
||||
X = (double)node["X"];
|
||||
id = (string)node["id"];
|
||||
}
|
||||
public: // Data Members
|
||||
int A;
|
||||
double X;
|
||||
string id;
|
||||
};
|
||||
|
||||
//These write and read functions must be defined for the serialization in FileStorage to work
|
||||
static void write(FileStorage& fs, const std::string&, const MyData& x)
|
||||
{
|
||||
x.write(fs);
|
||||
}
|
||||
static void read(const FileNode& node, MyData& x, const MyData& default_value = MyData()){
|
||||
if(node.empty())
|
||||
x = default_value;
|
||||
else
|
||||
x.read(node);
|
||||
}
|
||||
|
||||
// This function will print our custom class to the console
|
||||
static ostream& operator<<(ostream& out, const MyData& m)
|
||||
{
|
||||
out << "{ id = " << m.id << ", ";
|
||||
out << "X = " << m.X << ", ";
|
||||
out << "A = " << m.A << "}";
|
||||
return out;
|
||||
}
|
||||
|
||||
int main(int ac, char** av)
|
||||
{
|
||||
if (ac != 2)
|
||||
{
|
||||
help(av);
|
||||
return 1;
|
||||
}
|
||||
|
||||
string filename = av[1];
|
||||
{ //write
|
||||
Mat R = Mat_<uchar>::eye(3, 3),
|
||||
T = Mat_<double>::zeros(3, 1);
|
||||
MyData m(1);
|
||||
|
||||
FileStorage fs(filename, FileStorage::WRITE);
|
||||
|
||||
fs << "iterationNr" << 100;
|
||||
fs << "strings" << "["; // text - string sequence
|
||||
fs << "image1.jpg" << "Awesomeness" << "baboon.jpg";
|
||||
fs << "]"; // close sequence
|
||||
|
||||
fs << "Mapping"; // text - mapping
|
||||
fs << "{" << "One" << 1;
|
||||
fs << "Two" << 2 << "}";
|
||||
|
||||
fs << "R" << R; // cv::Mat
|
||||
fs << "T" << T;
|
||||
|
||||
fs << "MyData" << m; // your own data structures
|
||||
|
||||
fs.release(); // explicit close
|
||||
cout << "Write Done." << endl;
|
||||
}
|
||||
|
||||
{//read
|
||||
cout << endl << "Reading: " << endl;
|
||||
FileStorage fs;
|
||||
fs.open(filename, FileStorage::READ);
|
||||
|
||||
int itNr;
|
||||
//fs["iterationNr"] >> itNr;
|
||||
itNr = (int) fs["iterationNr"];
|
||||
cout << itNr;
|
||||
if (!fs.isOpened())
|
||||
{
|
||||
cerr << "Failed to open " << filename << endl;
|
||||
help(av);
|
||||
return 1;
|
||||
}
|
||||
|
||||
FileNode n = fs["strings"]; // Read string sequence - Get node
|
||||
if (n.type() != FileNode::SEQ)
|
||||
{
|
||||
cerr << "strings is not a sequence! FAIL" << endl;
|
||||
return 1;
|
||||
}
|
||||
|
||||
FileNodeIterator it = n.begin(), it_end = n.end(); // Go through the node
|
||||
for (; it != it_end; ++it)
|
||||
cout << (string)*it << endl;
|
||||
|
||||
|
||||
n = fs["Mapping"]; // Read mappings from a sequence
|
||||
cout << "Two " << (int)(n["Two"]) << "; ";
|
||||
cout << "One " << (int)(n["One"]) << endl << endl;
|
||||
|
||||
|
||||
MyData m;
|
||||
Mat R, T;
|
||||
|
||||
fs["R"] >> R; // Read cv::Mat
|
||||
fs["T"] >> T;
|
||||
fs["MyData"] >> m; // Read your own structure_
|
||||
|
||||
cout << endl
|
||||
<< "R = " << R << endl;
|
||||
cout << "T = " << T << endl << endl;
|
||||
cout << "MyData = " << endl << m << endl << endl;
|
||||
|
||||
//Show default behavior for non existing nodes
|
||||
cout << "Attempt to read NonExisting (should initialize the data structure with its default).";
|
||||
fs["NonExisting"] >> m;
|
||||
cout << endl << "NonExisting = " << endl << m << endl;
|
||||
}
|
||||
|
||||
cout << endl
|
||||
<< "Tip: Open up " << filename << " with a text editor to see the serialized data." << endl;
|
||||
|
||||
return 0;
|
||||
}
|
Before Width: | Height: | Size: 8.1 KiB |
Before Width: | Height: | Size: 6.8 KiB |
Before Width: | Height: | Size: 230 KiB |
Before Width: | Height: | Size: 282 KiB |
Before Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 176 KiB |
Before Width: | Height: | Size: 64 KiB |
Before Width: | Height: | Size: 546 KiB |
Before Width: | Height: | Size: 52 KiB |
Before Width: | Height: | Size: 16 KiB |
Before Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 37 KiB |
Before Width: | Height: | Size: 60 KiB |
Before Width: | Height: | Size: 463 KiB |
Before Width: | Height: | Size: 14 KiB |