Skip to content

Commit

Permalink
add partial imdecode implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
silverio.di committed Jun 25, 2022
1 parent c401604 commit 5b446f1
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
8 changes: 8 additions & 0 deletions source/imgcodecs.impl.inc
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,12 @@ begin
Result := imwrite(filename, img, a);
end;

function imdecode(const mat: TMat; flags: Integer): TMat;
var
InputArray: TInputArray;
begin
InputArray := TInputArray(mat);
Result := imdecode(InputArray, flags);
end;

{$ENDIF}
11 changes: 11 additions & 0 deletions source/imgcodecs.inc
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,17 @@ See cv::imread for the list of supported formats and flags description.
@param flags The same flags as in cv::imread, see cv::ImreadModes.
*)
//CV_EXPORTS_W Mat imdecode( InputArray buf, int flags );
function imdecode(
const buf: TInputArray;
const flags: Integer
): TMat; overload; external opencv_world_dll
{$IFDEF USE_DEBUG_DLLS}
name '?imdecode@cv@@YA?AVMat@1@AEBV_InputArray@debug_build_guard@1@H@Z'
{$ELSE}
name '?imdecode@cv@@YA?AVMat@1@AEBV_InputArray@1@H@Z'
{$ENDIF}
{$IFDEF DELAYED_LOAD_DLL} delayed{$ENDIF};
function imdecode(const mat: TMat; flags: Integer): TMat; overload; {$IFDEF USE_INLINE}inline; {$ENDIF}

(** @overload
@param buf
Expand Down

0 comments on commit 5b446f1

Please sign in to comment.