这个pas文件怎么用呢?

jojoxyz 2018-01-31 09:50:58
我想用delphi读取hdf5格式的文件,于是从网上找了个pas文件,但是不知道该怎么用?感觉要用到hdf5dll.dll,但是有没看到相关代码........


unit hdf5dll;

// Delphi wrapper for HDF5 library.

// Auto-generated 2017-06-22 by hdf5pas.py.

interface

uses
windows;

{$ALIGN ON}
{$MINENUMSIZE 4}

type
int32_t = Integer;
Pint32_t = ^int32_t;
uint32_t = Cardinal;
Puint32_t = ^uint32_t;
int64_t = Int64;
Pint64_t = ^int64_t;
uint64_t = UInt64;
Puint64_t = ^uint64_t;
time_t = NativeInt;
Ptime_t = ^time_t;
size_t = NativeUInt;
Psize_t = ^size_t;
ssize_t = NativeInt;
Pssize_t = ^ssize_t;
off_t = NativeInt;
Poff_t = ^off_t;
PFILE = Pointer;

type
hsize_t = UInt64;
Phsize_t = ^hsize_t;
hssize_t = Int64;
Phssize_t = ^hssize_t;
haddr_t = UInt64;
Phaddr_t = ^haddr_t;

const
HADDR_UNDEF = haddr_t(-1);

(* Version numbers *)
const
H5_VERS_MAJOR = 1; (* For major interface/format changes *)
H5_VERS_MINOR = 10; (* For minor interface/format changes *)
H5_VERS_RELEASE = 1; (* For tweaks, bug-fixes, or development *)
H5_VERS_SUBRELEASE = ''; (* For pre-releases like snap0 *)
(* Empty string for real releases. *)
H5_VERS_INFO = 'HDF5 library version: 1.10.1'; (* Full version string *)

(*
* Status return values. Failed integer functions in HDF5 result almost
* always in a negative value (unsigned failing functions sometimes return
* zero for failure) while successfull return is non-negative (often zero).
* The negative failure value is most commonly -1, but don't bet on it. The
* proper way to detect failure is something like:
*
* if((dset = H5Dopen2(file, name)) < 0)
* fprintf(stderr, "unable to open the requested dataset\n");
*)
type
herr_t = Integer;
Pherr_t = ^herr_t;

(*
* Boolean type. Successful return values are zero (false) or positive
* (true). The typical true value is 1 but don't bet on it. Boolean
* functions cannot fail. Functions that return `htri_t' however return zero
* (false), positive (true), or negative (failure). The proper way to test
* for truth from a htri_t function is:
*
* if ((retval = H5Tcommitted(type))>0) {
* printf("data type is committed\n");
* } else if (!retval) {
* printf("data type is not committed\n");
* } else {
* printf("error determining whether data type is committed\n");
* }
*)
type
...全文
2353 3 打赏 收藏 转发到动态 举报
写回复
用AI写文章
3 条回复
切换为时间正序
请发表友善的回复…
发表回复
jojoxyz 2018-05-12
  • 打赏
  • 举报
回复
试了一下,不行,必须要使用dll文件才行........
东南西北风 2018-02-27
  • 打赏
  • 举报
回复
这个 hdf5dll 不需要 DLL文件 ,可以在你的项目中的其它PAS文件中 直接 uses hdf5dll 即可 如hdf5dll这个pas 文件中使用了 windows uses windows;
lyhoo163 2018-02-01
  • 打赏
  • 举报
回复
另有hdf5dll.dll文件,网上可以下载。 这个pas文件,加入uses中,就可以使用了。

16,748

社区成员

发帖
与我相关
我的任务
社区描述
Delphi 语言基础/算法/系统设计
社区管理员
  • 语言基础/算法/系统设计社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧