I want to change the sop instance Uid, I found the following example. I searched the classes, I couldn't find things like dcmGenerateUniqueIdentifier, could you please tell me how to use it? What is the uid and how to define it? Thank you.
dataset->putAndInsertString(DCM_SOPInstanceUID, dcmGenerateUniqueIdentifier(uid, SITE_INSTANCE_UID_ROOT));
dcmGenerateUniqueIdentifier
Moderator: Moderator Team
-
- ICSMED DICOM Services
- Posts: 2217
- Joined: Fri, 2004-10-29, 21:38
- Location: Oldenburg, Germany
See "dcmdata/include/dcuid.h":
Code: Select all
/*
** char* generateUniqueIdentifier(char* uid)
** Creates a Unique Identifer in uid and returns uid.
** uid must be at least 65 bytes. Care is taken to make sure
** that the generated UID is 64 characters or less.
**
** If a prefix string is not passed as the second argument a
** default of SITE_INSTANCE_UID_ROOT (see below) will be used.
** Otherwise the supplied prefix string will appear at the beginning
** of uid.
**
** The UID is created by appending to the prefix the following:
** the host id (if obtainable, zero otherwise)
** the process id (if obtainable, zero otherwise)
** the system calendar time
** an accumulating counter for this process
*/
char* dcmGenerateUniqueIdentifier(char* uid, const char* prefix=NULL);
Who is online
Users browsing this forum: Ahrefs [Bot], Bing [Bot], Google [Bot] and 1 guest