[Kst] extragear/graphics/kst/src/datasources/cdf

Nicolas Brisset nicolas.brisset at eurocopter.com
Fri May 5 18:31:50 CEST 2006


SVN commit 537710 by brisset:

Changes to the CDF datasource, driven by the need to read CDF files written by the CDF routines bundled with Matlab (which are stored in a way that was not handled previously, for more information see the comments in the code). It is reasonably well tested here, if anybody gets a chance to test it further or takes a look at the code, comments are welcome.

While we were at it, we cleaned up the code a bit:
- indentation, especially for calls to CDFlib(...)
- data are read in whole chunks, while they were previously read one at a time. I suppose it should be faster, but I have not benchmarked it and with a few thousand samples the difference is not really noticeable
- frame counts are initialized directly while creating the field list
- the understands_cdf() function now returns 100.

Note that there is no locking mechanism in place for the case of concurrent access from different threads. I have not seen any crashes due to that (yet), but it may be good to keep it in mind as I'm not sure the CDF lib is threadsafe.


 M  +173 -78   cdf.cpp  




More information about the Kst mailing list