comparison Resources/Samples/OrthancClient/Vtk/main.cpp @ 591:a00f626290db

better api
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 02 Oct 2013 17:36:14 +0200
parents 3237eea24487
children 08eca5d86aad
comparison
equal deleted inserted replaced
590:3237eea24487 591:a00f626290db
141 // Try and find a 3D image inside the local store 141 // Try and find a 3D image inside the local store
142 OrthancClient::OrthancConnection orthanc("http://localhost:8042"); 142 OrthancClient::OrthancConnection orthanc("http://localhost:8042");
143 143
144 for (unsigned int i = 0; i < orthanc.GetPatientCount(); i++) 144 for (unsigned int i = 0; i < orthanc.GetPatientCount(); i++)
145 { 145 {
146 OrthancClient::Patient patient = orthanc.GetPatient(i); 146 OrthancClient::Patient patient(orthanc.GetPatient(i));
147 std::cout << "Patient: " << patient.GetId() << std::endl; 147 std::cout << "Patient: " << patient.GetId() << std::endl;
148 148
149 for (unsigned int j = 0; j < patient.GetStudyCount(); j++) 149 for (unsigned int j = 0; j < patient.GetStudyCount(); j++)
150 { 150 {
151 OrthancClient::Study study = patient.GetStudy(j); 151 OrthancClient::Study study(patient.GetStudy(j));
152 std::cout << " Study: " << study.GetId() << std::endl; 152 std::cout << " Study: " << study.GetId() << std::endl;
153 153
154 for (unsigned int k = 0; k < study.GetSeriesCount(); k++) 154 for (unsigned int k = 0; k < study.GetSeriesCount(); k++)
155 { 155 {
156 OrthancClient::Series series = study.GetSeries(k); 156 OrthancClient::Series series(study.GetSeries(k));
157 std::cout << " Series: " << series.GetId() << std::endl; 157 std::cout << " Series: " << series.GetId() << std::endl;
158 158
159 if (series.Is3DImage()) 159 if (series.Is3DImage())
160 { 160 {
161 Display(series); 161 Display(series);