mirror of
https://github.com/kerberos-io/openalpr-base.git
synced 2025-10-07 03:02:44 +08:00
Bugfix: Region of interest.
This commit is contained in:
@@ -409,8 +409,9 @@ namespace openalprnet {
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
AlprResultsNet^ Recognize(MemoryStream^ memoryStream, List<System::Drawing::Rectangle>^ regionsOfInterest)
|
AlprResultsNet^ Recognize(MemoryStream^ memoryStream, List<System::Drawing::Rectangle>^ regionsOfInterest)
|
||||||
{
|
{
|
||||||
std::vector<char> p = AlprHelper::MemoryStreamToVector(memoryStream);
|
std::vector<char> buffer = AlprHelper::MemoryStreamToVector(memoryStream);
|
||||||
AlprResults results = m_Impl->recognize(p);
|
std::vector<AlprRegionOfInterest> rois = AlprHelper::ToVector(regionsOfInterest);
|
||||||
|
AlprResults results = m_Impl->recognize(buffer, rois);
|
||||||
return gcnew AlprResultsNet(results);
|
return gcnew AlprResultsNet(results);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -427,9 +428,9 @@ namespace openalprnet {
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="imageBuffer">Bytes representing image data</param>
|
/// <param name="imageBuffer">Bytes representing image data</param>
|
||||||
AlprResultsNet^ Recognize(cli::array<Byte>^ imageBuffer, List<System::Drawing::Rectangle>^ regionsOfInterest) {
|
AlprResultsNet^ Recognize(cli::array<Byte>^ imageBuffer, List<System::Drawing::Rectangle>^ regionsOfInterest) {
|
||||||
std::vector<char> p = AlprHelper::ToVector(imageBuffer);
|
std::vector<char> buffer = AlprHelper::ToVector(imageBuffer);
|
||||||
std::vector<AlprRegionOfInterest> rois = AlprHelper::ToVector(regionsOfInterest);
|
std::vector<AlprRegionOfInterest> rois = AlprHelper::ToVector(regionsOfInterest);
|
||||||
AlprResults results = m_Impl->recognize(p, rois);
|
AlprResults results = m_Impl->recognize(buffer, rois);
|
||||||
return gcnew AlprResultsNet(results);
|
return gcnew AlprResultsNet(results);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user