integer function fdds_read(bin, tag, buf, count)
tag is a field tag, previously obtained, for example, from fdds_member. It specifies a tag associated with bin. This provides a scale factor for count. If tag is zero (nominal), it defaults to the SEQUENCE (trace type) associated with bin.
Data is read into buf. The minimum size is count times the size of tag.
#include <fdds.h>
integer in_bin
integer buf(*)
...
! read 10 traces into type buffer
j = fdds_read(in_bin, 0, buf, 10)
In free-format F90:
#include <f90dds.h>
integer in_bin
integer buf(*)
...
! read 10 traces into type buffer
j = fdds_read(in_bin, 0, buf, 10)
Using the DDS module:
(Note that the DDS module requires that data arrays passed to I/O
functions be 1 dimensional.)
use dds
integer :: in_bin, nsmp, ntrc, itrc
real, allocatable :: buffer(:,:)
allocate(buffer(nsmp, ntrc))
! read 10 traces into buffer
do itrc=1,10
ier = fdds_read(in_bin, 0, buffer(:,itrc), 1)
enddo
fdds_readm Read & map
fdds_write Write data
fdds_writem Map & write