// PhBScatterer.H: PhBScatterer nodes.

// This file has been generated using nodegen 0.5a.
// Restrict manual editing to the sections delimited by
// . the comments "utility includes" and "end of utility includes"
// . the comments "utility members" and "end of utility members"

#ifndef _PhBScatterer_H_
#define _PhBScatterer_H_

#include "xrml.H"

// utility includes
#include "smodes.H"
#include "complex.H"
#include "spectrum.H"
#include "vector.H"
// end of utility includes

namespace xrml {
#define PhBScattererTypeId 	"PhBScatterer"
extern bool IsPhBScatterer(SFNode*);

class PhBScatterer: public virtual SFNode {
public:
  //
  virtual int major_version(void), minor_version(void);
  virtual bool is_leaf_class(void);
  
  PhBScatterer();
  
  //
  virtual void     	render(void);
  
  // utility members
  virtual float albedo(const Vec3& inDir,
		       const complex& IndexIn,
		       const complex& IndexOut,
		       int modes)
    {
      Warning(NULL, "%s::albedo(): not yet implemented",
	      typeId);
      return 0.;
    }

  virtual Vec3 sample(const Vec3& inDir,
		      const complex& IndexIn,
		      const complex& IndexOut,
		      float xi1, float xi2,
		      int modes)
    {
      Warning(NULL, "%s::sample(): not yet implemented",
	      typeId);
      return Vec3(0.,0.,1.);
    }

  virtual float eval(const Vec3& inDir,
		     const Vec3& outDir,
		     const complex& IndexIn,
		     const complex& IndexOut,
		     int modes, 
		     float *pdf)
    {
      Warning(NULL, "%s::eval(): not yet implemented",
	      typeId);
      if (pdf) *pdf = 0.;
      return 0.;
    }

  
protected:
  inline void util_init(void) { }
  inline void util_clone(const PhBScatterer& src) { }
  inline void util_destruct(void) { }
};

// end of utility members
} // namespace xrml
#endif /*_PhBScatterer_H_*/
