[ITK] reading private tags returns weird strings

Dženan Zukić dzenanz at gmail.com
Wed Aug 10 10:22:56 EDT 2016


Does Matlab have special support for those private tags? They may have
special encoding besides base64 applied by ITK DICOM dictionary.

On Wed, Aug 10, 2016 at 10:13 AM, <Francois.GIRINON at ensam.eu> wrote:

> Le 10/08/2016 à 16:05, Dženan Zukić a écrit :
>
> In fact, this decodes
> <http://www.opinionatedgeek.com/dotnet/tools/base64decode/> to 00 80 93
> 43 - four bytes given here in hexadecimal notation. The decoder you linked
> does not seem to work correctly. I don't know why you expect 295 there.
>
> On Wed, Aug 10, 2016 at 9:58 AM, <Francois.GIRINON at ensam.eu> wrote:
>
>> Le 10/08/2016 à 14:35, Dženan Zukić a écrit :
>>
>> Hi Francois,
>>
>> is this base64 encoded? You should perhaps do base64 decode on the return
>> string to get the binary value.
>>
>> Regards,
>> Dženan
>>
>> On Wed, Aug 10, 2016 at 7:15 AM, <Francois.GIRINON at ensam.eu> wrote:
>>
>>> Hi,
>>>
>>> I'm trying to read private dicom tags using :
>>>
>>>     ImageIOType::Pointer dicomIO = ImageIOType::New();
>>>     ...
>>>     dicomIO->SetLoadPrivateTags(true);
>>>     std::string offsetFromBottomStr;
>>>
>>>     std::string offsetFromBottom = "0863|1041";
>>>     dicomIO->GetValueFromTag(offsetFromBottom, offsetFromBottomStr);
>>>
>>> The value *offsetFromBottomStr *returned is *AICTQw==*
>>> How does it come and how can I fix this ?
>>>
>>> Thank you,
>>> François.
>>>
>>> _______________________________________________
>>> Community mailing list
>>> Community at itk.org
>>> http://public.kitware.com/mailman/listinfo/community
>>>
>>>
>> Thanks for your answer. You might be right, they say here
>> <http://public.kitware.com/pipermail/community/2016-May/011426.html>
>> *private tags and encodes the with Base64 into strings. *Unfortunately, *AICTQw==
>> *should correspond to 295 and according to https://www.base64decode.org/,
>> *AICTQw==* is a C.
>> Besides, I don't understand how does itksysBase64_Decode works (I'm not
>> sure I should use this method too).
>>
>
> In fact I have previously red the dicom using matlab and the value of the
> private tag 0863 1041 is 295.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/community/attachments/20160810/b26864fe/attachment.html>


More information about the Community mailing list