|
You haven't set the camera perspective
Your frustum seems to extend only from -1 to 1 . your translation at the beginning (glTranslatef(-1.5f,0.0f,-6.0f);) takes you object beyond the far plane.
try setting the camera parameters or change you glTranslatef line
I hope this helps
"It was when I found out I could make mistakes that I knew I was on to something."
-Ornette Coleman
"Philosophy is a study that lets us be unhappy more intelligently."
-Anon.
|
|
|
|
|
First, when you have an error, explain what it is (instead of saying error lnk2019). That way, we don't need to google to find what the exact error is.
Also, when posting coed, use the code tag so that your code will look better.
Now, to your question, I see several problems:
#ifdef MYDLL_EXPORTS<br />
#define MYDLL_EXPORTS __declspec(dllexport)<br />
#else<br />
#define MYDLL_EXPORTS __declspec(dllimport)<br />
#endif
What are you trying to do here ? Why do you use the same symbol (MYDLL_EXPORTS) ? You need to have two compiler flags: one to specify if symbols need to be exported or imported and the second that will contain the export or import directive. Something like that:
#ifdef ISDLL<br />
#define MYDLL_EXPORTS __declspec(dllexport)<br />
#else<br />
#define MYDLL_EXPORTS __declspec(dllimport)<br />
#endif
Then, you can add ISDLL in the compiler flag (project options) if you are compiling your dll.
You don't export anything also. Even if your flags were defined correctly, you still don't use them to export your classes.
|
|
|
|
|
There is no problem with my flags actually, it is my error during copy&paste.(Sorry)
and also could not recognize the code tag(Sorry again).
I have corrected my flags by modifying my post and also mentioned the project that mine is based on(http://www.codeproject.com/dll/rsLoadtimeDLL.asp).
This example works properly.I added another class to win32dll project and used its methods from win32app project. Project properties of Load Time dll Sample and mine are the same.
Can it be about my #include header directives?
Thanx...
|
|
|
|
|
baharat wrote: There is no problem with my flags actually, it is my error during copy&paste
If you don't post the right code, it is impossible for us to help you. Did you export the functions from you class as I said in my previous post ? Or was that part also a typo ?
baharat wrote: Can it be about my #include header directives?
No, if the include directive was wrong, then you'll get a compile error, not a link error. The problem here is that the function is not found in the library.
|
|
|
|
|
another dumb man who deleted his question after getting the answer...
|
|
|
|
|
Don't they just annoy you
I have a feeling these little children are trying to do their homework and they don't want their classmates to see just how dumb they are!
|
|
|
|
|
yup.
|
|
|
|
|
Hi!
How do i show a browse dialog box?
for example : DoModal function of CFileDialog calss show an open file or save file dialog box.
but to select a directory, i need browse dialog box.
please help me
-- modified at 4:22 Monday 2nd October, 2006
Zo.Naderi-Iran
|
|
|
|
|
open/save allows you to change the directory. Can you be a little more specific.
|
|
|
|
|
I guess his question is SHBrowseForFolder becuase he said a dialog for select directory .
|
|
|
|
|
|
Hello!
Which tool can I use under win32 to see which symbols are linked in the to the libray someLib.lib. I can use "nm" utility under Linux (example: someLib.a). Is there some simmilar tool for MSVC constructed libraries? I use MSVC++ .NET 2003.
Regards,
Rostfrei
|
|
|
|
|
Try using depends.exe, not sure if will look at a .lib file though, I know it works for .dlls
|
|
|
|
|
Thank you for response waldermort and benjymous. I tried both tools and it looks like it's the same tool. One comes with .NET installation and another can be downloaded from net. Both were unsuccessful in my case. They work when I open some DLL but when I open LIB file, I get "Error: At least one file was not a 32-bit or 64-bit Windows module." Is there some other tool I can use?
Regards,
Rostfrei
|
|
|
|
|
Depends.exe and other dependency walking tools will only show the imports and exports in a DLL or EXE; I don't believe this is what you're after. I think the tool you need is Dumpbin[^] which comes with Visual Studio. Using this you can examine the symbols and contents of LIB and OBJ files.
Steve
|
|
|
|
|
That is exactly what I needed.
For anybody else: for Dumpbin to work you need to put "C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\bin" to the PATH and also "C:\Program Files\Microsoft Visual Studio .NET 2003\Common7\IDE" because Dumpbin needs mspdb71.dll to work.
Thank you Stephen!
Regards,
Marko Kukovec
|
|
|
|
|
hi i am working on serial port communication,i have opened the port using CreateFile function ,wrote the data using WriteFile function,and Read data using ReadFile Function.Every thing is fine until here,Say for Example..the instrument is switched off..but connected to the port..how do detect whether the instrument is switched ON or OFF...?
thanks in before
James
|
|
|
|
|
You should check the documentation of your instrument. Maybe when switched ON, there is one line that is set to high (I think it is the DTR - Data Terminal Ready). If this is the case, just check for the status of this line. Otherwise you can always send something to which the instrument is supposed to respond. If you don't get an answer, then the device is either not connected, either switched OFF. I don't think it is possible to make a difference between disconnected and switched off.
|
|
|
|
|
how to check DTR..is there any API fucntion for it..?
|
|
|
|
|
I think you can use GetCommModemStatus[^]. I think I was wrong, you have to check for the DSR (Data Set Ready) line, not the DSR (I always mix them).
|
|
|
|
|
Is there any other alternative..?..i have tried used GetCommModemStatus function..its returning false..even if..the instrument is switched on..
|
|
|
|
|
Did you pass the correct handle ? After the port has been opened ?
RockyJames wrote: Is there any other alternative..?..
Yes, as I said previously: send something to which your device is supposed to answer. If you don't receive an answer, then the device is not connected or switched off.
|
|
|
|
|
yeah i have sent..correct handle..i have opened port it in OVERLAPPED MODE..i am using WaitForSingleObject function..when i write data ..its able to write..when i start reading the data..it is getting stucked..at WaitForSingleObject function..
|
|
|
|
|
thank`s for u r support..issuse is closed..i have done..with the commtimeout....
|
|
|
|
|
As Cedric Moonen already said, you can check the DSR signal.
In addition you should raise the RTS (Request To Send) signal and check for the reply from the device, CTS (Clear To Send). If you get a transition from Off to On in the CTS line, you can be pretty sure the device is powered on.
For the serial communication, i suggest you use a serial commuinications library, the are some good ones here at CP.
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson
|
|
|
|