3 * Copyright 2006 Free Software Foundation, Inc.
5 * This file is part of GNU Radio
7 * GNU Radio is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2, or (at your option)
12 * GNU Radio is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with GNU Radio; see the file COPYING. If not, write to
19 * the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
20 * Boston, MA 02111-1307, USA.
27 #include <atsc_fs_checker.h>
28 #include <create_atsci_fs_checker.h>
29 #include <atsci_fs_checker.h>
30 #include <gr_io_signature.h>
31 #include <atsc_consts.h>
32 #include <atsci_syminfo.h>
36 atsc_make_fs_checker()
38 return atsc_fs_checker_sptr(new atsc_fs_checker());
41 atsc_fs_checker::atsc_fs_checker()
42 : gr_sync_block("atsc_fs_checker",
43 gr_make_io_signature(2, 2, sizeof(float)),
44 gr_make_io_signature(2, 2, sizeof(float)))
46 d_fsc = create_atsci_fs_checker();
50 atsc_fs_checker::~atsc_fs_checker ()
52 // Anything that isn't automatically cleaned up...
59 atsc_fs_checker::work (int noutput_items,
60 gr_vector_const_void_star &input_items,
61 gr_vector_void_star &output_items)
63 const float *in = (const float *) input_items[0];
64 const atsc::syminfo *tag_in = (const atsc::syminfo *) input_items[1];
65 float *out = (float *) output_items[0];
66 atsc::syminfo *tag_out = (atsc::syminfo *) output_items[1];
68 assert(sizeof(float) == sizeof(atsc::syminfo));
71 for (int i = 0; i < noutput_items; i++)
72 d_fsc->filter (in[i], tag_in[i], &out[i], &tag_out[i]);