Read only valid samples

3 posts / 0 new
Last post
Offline
Last seen: 4 years 6 months ago
Joined: 09/17/2015
Posts: 53
Read only valid samples

Hello all,

I have a lot of code like

auto samples = dr.read();for(auto s: samples) {if(s.valid()){ do stuff  } }

I'd like to have a selector like:

auto samples = dr.select(ValidSamplesOnly).read();

Is there a function like that? I didn't find it in the doucmentation.

Thank you,

Andreas

Gerardo Pardo's picture
Offline
Last seen: 1 month 3 days ago
Joined: 06/02/2010
Posts: 598

Hello,

You could perhaps use the ValidSampleIterator as shown in the documentation here.

Gerardo

 

Offline
Last seen: 2 years 11 months ago
Joined: 12/07/2016
Posts: 10

Gerardo, does this functionality exist in Traditional C++ API?