Jump to content

LNK2001, cant get past.


shadmar
 Share

Recommended Posts

How do I go finding what is wrong with this, I have no external libs dependencies, just a class called complex which defines a datatype for a public member in the co class. I can't seem to figure it out.

 

Error    3    error LNK2001: unresolved external symbol "public: class complex __thiscall co::hTilde_0(int,int)" (?hTilde_0@co@@QAE?AVcomplex@@HH@Z)    C:\Users\Documents\Leadwerks\Projects\cpp_co\Projects\Windows\co.obj    cpp_co

 

Any tip?

HP Omen - 16GB - i7 - Nvidia GTX 1060 6GB

Link to comment
Share on other sites

Well it's keiths ocean class here : http://www.keithlantz.net/2011/10/ocean-simulation-part-one-using-the-discrete-fourier-transform/

I'm giving a FFT water a go if I figure out how to compile his classes and adapt to Leadwerks.

 

This is the class:

 

class cOcean {
 private:
   bool geometry;						  // flag to render geometry or surface

   float g;							    // gravity constant
   int N, Nplus1;						  // dimension -- N should be a power of 2
   float A;							    // phillips spectrum parameter -- affects heights of waves
   vector2 w;							  // wind parameter
   float length;						   // length parameter
   complex *h_tilde,					   // for fast fourier transform
    *h_tilde_slopex, *h_tilde_slopez,
    *h_tilde_dx, *h_tilde_dz;
   cFFT *fft;							  // fast fourier transform

   vertex_ocean *vertices;				 // vertices for vertex buffer object
   unsigned int *indices;				  // indicies for vertex buffer object
   unsigned int indices_count;			 // number of indices to render
   //GLuint vbo_vertices, vbo_indices;	   // vertex buffer objects

   //GLuint glProgram, glShaderV, glShaderF; // shaders
   //GLint vertex, normal, texture, light_position, projection, view, model; // attributes and uniforms

 protected:
 public:
   cOcean(const int N, const float A, const vector2 w, const float length, bool geometry);
   ~cOcean();
   void release();

   float dispersion(int n_prime, int m_prime);	 // deep water
   float phillips(int n_prime, int m_prime);	   // phillips spectrum
   complex hTilde_0(int n_prime, int m_prime);
   complex hTilde(float t, int n_prime, int m_prime);
   complex_vector_normal h_D_and_n(vector2 x, float t);
   void evaluateWaves(float t);
   void evaluateWavesFFT(float t);
   //void render(float t, glm::vec3 light_pos, glm::mat4 Projection, glm::mat4 View, glm::mat4 Model, bool use_fft);
};

HP Omen - 16GB - i7 - Nvidia GTX 1060 6GB

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...