/* This file is part of the Neper software package. */
/* Copyright (C) 2003-2014, Romain Quey. */
/* See the COPYING file in the top-level directory. */

#include"net_seed_reg_.h"

void
net_seed_reg (struct TESS Dom, struct SEEDSET *pGSet)
{
  if (!strcmp ((*pGSet).morpho, "square"))
    net_seed_reg_square (Dom, pGSet);
  else if (!strcmp ((*pGSet).morpho, "cube"))
    net_seed_reg_cube (Dom, pGSet);
  else if (!strcmp ((*pGSet).morpho, "tocta"))
    net_seed_reg_tocta (Dom, pGSet);
  else
    ut_error_reportbug ();

  // Re'allocing SeedWeight since N has been modified.
  ut_free_1d ((*pGSet).SeedWeight);
  (*pGSet).SeedWeight = ut_alloc_1d ((*pGSet).N + 1);

  return;
}
