Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
ee144852
Commit
ee144852
authored
Dec 20, 2012
by
Alexander Smorkalov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Hardware platform detection for non arm devices fixed.
parent
c8b658fd
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
7 deletions
+15
-7
CommonPackageManager.cpp
...service/engine/jni/NativeService/CommonPackageManager.cpp
+15
-7
No files found.
android/service/engine/jni/NativeService/CommonPackageManager.cpp
View file @
ee144852
...
...
@@ -134,7 +134,7 @@ bool CommonPackageManager::IsVersionCompatible(const std::string& target_version
// major version is the same and minor package version is above or the same as target.
if
((
package_version
[
0
]
==
target_version
[
0
])
&&
(
package_version
[
1
]
==
target_version
[
1
])
&&
(
package_version
[
2
]
>=
target_version
[
2
]))
{
result
=
true
;
result
=
true
;
}
return
result
;
...
...
@@ -144,13 +144,21 @@ int CommonPackageManager::GetHardwareRating(int platform, int cpu_id, const std:
{
int
result
=
-
1
;
for
(
size_t
i
=
0
;
i
<
group
.
size
();
i
++
)
if
((
cpu_id
&
ARCH_X86
)
||
(
cpu_id
&
ARCH_X64
)
||
(
cpu_id
&
ARCH_MIPS
))
// Note: No raiting for x86, x64 and MIPS
// only one package is used
result
=
0
;
else
{
if
(
group
[
i
]
==
std
::
pair
<
int
,
int
>
(
platform
,
cpu_id
))
{
result
=
i
;
break
;
}
// Calculate rating for Arm
for
(
size_t
i
=
0
;
i
<
group
.
size
();
i
++
)
{
if
(
group
[
i
]
==
std
::
pair
<
int
,
int
>
(
platform
,
cpu_id
))
{
result
=
i
;
break
;
}
}
}
return
result
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment