[Insight-users] read a meta image and write a volume to DICOM

wordon m9421001 at gmail.com
Thu Sep 15 11:56:12 EDT 2005


VGhhbmtzIGZvciB5b3VyIGhlbHAuCkJ1dCB3aGVuIEkgdHJ5IHRvIGZpeCBteSBjb2RlIGFzIGZv
bGxvd3M6Cj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KCnR5
cGVkZWYgaXRrOjpHRENNSW1hZ2VJTyAgICAgICAgSW1hZ2VJT1R5cGU7CgpJbWFnZUlPVHlwZTo6
UG9pbnRlciBnZGNtSW1hZ2VJTyA9IEltYWdlSU9UeXBlOjpOZXcoKTsKCnR5cGVkZWYgaXRrOjpJ
bWFnZTx1bnNpZ25lZCBjaGFyLCAzPiBJbWFnZVR5cGU7Cgp0eXBlZGVmIGl0azo6SW1hZ2VGaWxl
UmVhZGVyPCBJbWFnZVR5cGUgPiBWb2x1bWVSZWFkZXJUeXBlOwoKVm9sdW1lUmVhZGVyVHlwZTo6
UG9pbnRlciByZWFkZXIgPSBWb2x1bWVSZWFkZXJUeXBlOjpOZXcoKTsKCnJlYWRlci0+U2V0SW1h
Z2VJTyggZ2RjbUltYWdlSU8gKTsKCnJlYWRlci0+U2V0RmlsZU5hbWUoIGF2WzFdICk7Ci4KLgpy
ZWFkZXItPlVwZGF0ZSgpOwouCi4KPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09
PT09PT09PT09PT0KYW5kIGdldCBhICdlcnJvcicgYXMgZm9sbG93czoKCkVycm9yIDoKZXhjZXB0
aW9uIGluIGZpbGUgcmVhZGVyCml0azo6RVJST1I6IEdEQ01JbWFnZUlPKDAwM0QyNDQ4KTogVW5y
ZWNvZ25pemVkIHR5cGU6MFMgaW4gZmlsZQpCcmFpblByb3RvbkRlbnNpdHkzU2xpY2VzLm1oYQpV
bmtub3duCgppcyBpdCByaWdodCBpbiBteSBjb2RlPwoKMjAwNS85LzE1LCBEaWVnbyBQYXJhZGEg
PGljZWJpc2hvcEBn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