|
See here.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Hi all:
Can I release a program without bring Msvcr80d.dll along? In other words can a program release without Msvcr80d.dll? What it is for exactly? It seems this dll is only used when you want to debug.
|
|
|
|
|
MSVCR80d.dll can not be redistributed. What you have to do is build the release version of your app and distribute it with MSVCR80.dll
You may be right I may be crazy -- Billy Joel --
Within you lies the power for good, use it!!!
|
|
|
|
|
PJ Arends wrote: MSVCR80d.dll can not be redistributed.
What do you mean by "REdistributed"?
|
|
|
|
|
Microsoft has already distributed the file with your development tools, that is how you got it. If you were to send it out you would be redistributing it.
You may be right I may be crazy -- Billy Joel --
Within you lies the power for good, use it!!!
|
|
|
|
|
OK, thanks, now I understood what "Redistribute" means.
Please allow me to ask another question which is not about tech, but pure matter about language grammar.
you wrote: If you were to send it out
What "were to" in the above sentence means, is it a presumption like "If I were you"? Sorry, if this seems irrelevant.
|
|
|
|
|
Yes, it is a presumption. The word 'if' is what makes it a presumption.
You may be right I may be crazy -- Billy Joel --
Within you lies the power for good, use it!!!
|
|
|
|
|
Sorry for posting so much in a row I am just having severe problems that don't seem right. Anyway for the next I have very similar code. In the following code i get error C2440: '=' : cannot convert from 'Vector' to 'float'. I thought that the [] overload should return a float so why is it trying to convert it from a vector to a float?
Thanks for any help givin.
int main
{
Vector* Test1 = new Vector(3);
float Test10(0);
Test10 = Test1[0];
}
Base class Array header
float& operator[](const int RHS);
const float& operator[](const int RHS) const;
|
|
|
|
|
Test1 is a pointer to a Vector . Test1[0] is the same as *Test1 , which returns a Vector . What you want is (*Test1)[0] to call the operator[] method of the Vector object.
|
|
|
|
|
I have some problems with overloading + operator I think??? What I have is a static library with 2 classes array is the base class and just has the array basic functions and the overloaded[]. The Vector class has the arithmatic functions. with the following code i get the error cannot add 2 pointers but shouldn't the overload take care of that?
here is what i have
int Main
{
Vector* Test1 = new Vector(3);
Vector* Test3(NULL);
Test3 = Test1 + Test1;
}
Vector header
friend Vector& operator+(const Vector& LHS, const Vector& RHS);
|
|
|
|
|
What are you trying to do? Adding two pointers together isn't going to yield anything useful
except a bad pointer.
Mark
|
|
|
|
|
I am trying to use the overload to do vector addition. That code should call my overload right?
|
|
|
|
|
Your "+" operator overload takes two Vector references and you are passing it two Vector
pointers.
|
|
|
|
|
How do I pass it 2 references? I have already tried *Test1 + *Test1 and &Test1 + &Test1 and neither will work.
|
|
|
|
|
I'm still not clear what you are trying to do...
What is a "Vector" and why do you pass 3 to its constructor?
Maybe this...(?)
int Main
{
Vector* Test1 = new Vector(3);
Vector Test3(NULL);
Test3 = *Test1 + *Test1;
}
|
|
|
|
|
I got it
it was (*Test3) = (*Test1) + (*Test1);
|
|
|
|
|
Test3 was an unallocated pointer in your original code. That's not good ((*Test3) = ...)
|
|
|
|
|
First, ask yourself this question: What is the sum of two addresses? (Hint: A similar question is: What is the sum of two offset values?)
To solve your particular problem:
Vector Test1(3);
Vector Test3 = Test1 + Test1;
--
Not Y3K Compliant
|
|
|
|
|
Now I get
TestLibMain.obj : error LNK2019: unresolved external symbol "public: float & __thiscall Array::operator[](int)" (??AArray@@QAEAAMH@Z) referenced in function _main
ArrayLib.lib(Vector.obj) : error LNK2001: unresolved external symbol "public: float & __thiscall Array::operator[](int)" (??AArray@@QAEAAMH@Z)
ArrayLib.lib(Vector.obj) : error LNK2019: unresolved external symbol "public: float const & __thiscall Array::operator[](int)const " (??AArray@@QBEABMH@Z) referenced in function "class Vector & __cdecl operator+(class Vector const &,class Vector const &)" (??H@YAAAVVector@@ABV0@0@Z)
|
|
|
|
|
Hello i have a problem with event sink. I need to contol a NewWindow when it pops-up (to change if its visible toolbar)
i'm not sure about pDispParams->rgvarg[1].pdispVal; parametr. SOmehow i dont have handle to the new window.
Please help...
Code for NEWWINDOW2 event:
HRESULT __stdcall DWebBrowserEventsImpl::Invoke(DISPID dispIdMember,
REFIID riid,
LCID lcid,
WORD wFlags,
DISPPARAMS __RPC_FAR *pDispParams,
VARIANT __RPC_FAR *pVarResult,
EXCEPINFO __RPC_FAR *pExcepInfo,
UINT __RPC_FAR *puArgErr)
{
if (dispIdMember == DISPID_NEWWINDOW2)
{
//event sink is working because i can get a test message every time a new window pops
//but somehow i cant control a new wondow ?
MessageBox(NULL,"TEST","TEST",NULL);
//////////////////////////////////////////////////////////// this part wont work ?
CComQIPtr< IWebBrowser2> Nwin= pDispParams->rgvarg[1].pdispVal;
Nwin->put_Visible(TRUE);
Nwin->put_MenuBar(TRUE);
Nwin->put_ToolBar(FALSE);
}
return NOERROR;
}
|
|
|
|
|
I am currently designing a 2D/3D interface package based on Direct3D, but need to include a DirectShow VMR9 window in the interface which will be diplaying video from a capture card or pre-recorded videos.
The problem is that I have a render loop that constantly updates and redraws the interface, which causes the embedded video to flash. Is there a way that I can tell part of a surface not to be redrawn, i.e. the surface behind the vid window? It is on top of a large fullscreen size surface which holds a background image. Else is there a simple way to place individual frames of a my video onto a Direct3D surface which can then be drawn on top of the backgroung image.
I'm fairly new to Direct3D and very new to DirectShow. Any help is appreciated.
Thanks,
Dustin
|
|
|
|
|
|
I have a static boolean :
static bool booleanValue= true;
in my stdafx.h file.
I assumed this variable would have one instance across my application. But this assumption is apparently wrong. Within different objects, this boolean has separate instances, thus voiding its use.
I.E.
------------------------------
Have a class:
#include "stdafx.h"
class Blah {
int stuff;
void doStuff() {
if (!booleanValue) {
stuff++;
}
}
};
Have another class"
#include "stdafx.h"
class AnotherClass {
int stuffedPeppers;
void intoTheAbyss() {
if (!booleanValue) {
stuffedPeppers++;
}
}
};
------------------------------
The addresses for the same variable are different (same thread).
Where am I going wrong?
|
|
|
|
|
There's an instance for every module which includes the stdafx.h header file.
Try
In stdafx.h:
extern bool booleanValue;
And in one cpp file:
static bool booleanValue= true;
|
|
|
|
|
That worked. Thanks!
Had to use just:
bool booleanValue = true;
in cpp file.
So should this be done for functions as well?
|
|
|
|