|
Hi all,
I've wrote an application based on the DirectX StillCap example, which allows the user to get the latest frame and then performs whatever segmentation methods they want on it. The problem which I have came across is that I appear to have more data than I am expecting! I'm expecting an 320x240 RGB image but the buffer I get is 233,472 long instead of 230,400 (i.e. 320x240x3).
Does anyone know what these extra 3,072 bits are (I'm guessing they may be header information)? And also where abouts in the stream they are appearing? as I'm not missing any information from the image when I save it so I'm assuming that is is probably at the end of the buffer (I've saved the buffer as a RAW image and then opened it up in Paint Shop Pro and everything appears fine)
Many Thanks,
Andy
|
|
|
|
|
Hi All,
searched high 'n low, and can't find a function/or where to look, to see if a system has usb ports installed. don't need to know what the devices are, just if the motherboard has a usb port.
needs to be c/c++, no wmi, function must be compatible with w98/w2k/xp
any help or advice appreciated
|
|
|
|
|
You might try the Win32_USBController and Win32_USBControllerDevice WMI classes.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
Hi David,
thanks for he info, but i can't use WMI, gonna make the app too fat for its purpose with com and all the other stuff.
plus the app needs to run and detect on w98 systems, which WMI is not activated by default, and the end users are not bright enough to start hacking the registry.
any way with using WMI ??
thanks again
|
|
|
|
|
any with using WMI SHOULD BE:
any way without using WMI
|
|
|
|
|
is there an easy 1 line or inline way of converting a CString into a basic_string of TCHARs?
Joel Holdsworth
|
|
|
|
|
How about:
string str;
CString cstr("Hello");
str = (LPCTSTR) cstr; or:
basic_string<TCHAR> str;
CString cstr("Hello");
str = (LPCTSTR) cstr;
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
Oh yeah .... Thanks for that! I gues I got a bit freak out when the compiler spat out template filled error messages!
Joel Holdsworth
|
|
|
|
|
I want suggestions with the things needed to be considered when am doing
1.Encryption of a file with AES(RIJNDAEL) algorithum using javax.crypto.* in a java application. and
2.Decryption of the encrypted stuff mentioned above in VC++ .
To be more clear,i am encrypting a file using the java 1.4 libraries and wants to decrypt the same encrypted file using VC++.
RAGU MANDA
(MALAYSIA)
|
|
|
|
|
The encryption library should not affect the underlying algorithm. In other words, you should be able to encrypt the data using one library and then decrypt it using a different library.
Kuphryn
|
|
|
|
|
If I call AfxEndThread within a thread will the dynamic memory that I have allocated in this thread be released or just the memory that MFC itself have allocated for it's inner needs. Thanks.
|
|
|
|
|
Until you call delete or the application is shut down, the memory remains allocated.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
I am writing two ActiveX objects in MFC 7, one server and one client. I want my client object to connect to the server object through the Internet(not LAN); how can I pass through the firewalls/proxy that reside on the Internet ?
|
|
|
|
|
Hello everyone.
I am quite new at COM and DirectX programming, and I have some problems to understand how to use properly all of this stuff to build my own transform filter.
My app take the voice as an input, convert it into UMTS format and send it through the internet, at the end of it, the data stream is uncompressed and played. But this is just my dream. For now I would like to know how to build a Transform filter, and how to use the CTransformFilter interface.
I have started to build a COM object with VC++ ATL Wizard, but any "public CTransformFilter" throws me away, even if the appropriate "#include "Streams.h" and "Strmbased.lib" in the Settings.
Thanks for any kind of help.
|
|
|
|
|
When I using SetIpNetEntry( ), I got wrong IP in ARP Table
MIB_IPNETROW at1;
...
at1.dwAddr = inet_addr("80.0.0.30");
//or at1.dwAddr = pMib->table[0].dwAddr;
SetIpNetEntry((MIB_IPNETROW *)&at1);
Then I get 0.0.0.30 in ARP Table instead of 80.0.0.30.
Even if I get MIB_IPNETROW by means of GetIpNetTable( ) and then insert it to SetIpNetEntry( ) I get 0.0.0.X
Help me.
|
|
|
|
|
When I using SetIpNetEntry( ), I got wrong IP in ARP Table
MIB_IPNETROW at1;
...
at1.dwAddr = inet_addr("80.0.0.30");
//or at1.dwAddr = pMib->table[0].dwAddr;
SetIpNetEntry((MIB_IPNETROW *)&at1);
Then I get 0.0.0.30 in ARP Table instead of 80.0.0.30.
Even if I get MIB_IPNETROW by means of GetIpNetTable( ) and then insert it to SetIpNetEntry( ) I get 0.0.0.X
Help me.
|
|
|
|
|
hi all,
I have ATL composite control, when the control in loaded is IE the background color is changed (to white). I want the default background color for my composite control dialog box.
Do i have to create a brush and set the background color?
Thanks in Advance
Abhi Lahare
|
|
|
|
|
Hi guys,
I am going to add Tab control to my Project.There are 3 Tab labels in my Tab Control.Now I want to add Images to Tablabel. BUT I DON'T WANT TO ADD TEXT FOR that Label.I just want to add a Image Completely to the Label.
I do like this:
CImageList img;
CTabControl m_tabctrl;
img.Create(IDB_BITMAP2, 11, 4, RGB(0, 255, 0));
m_tabctrl.SetImageList(&m_imagelistTab);
pfirst=new first;-------->This is a Pointer from a dialog..
pfirst->Create(first::IDD, &m_tabctrl);
m_tabctrl.AddTab(pfirst,"", 0);
The Image is adding to the Label.But there is a small space remaining in the Label.I don't want to add Text to the Label.
So How do I add Image completely to the Tablabel with out remainng Space?
Thanks...
|
|
|
|
|
Hi all,
I want to call a CDAODatabase class from my Regular MFC DLL, I have followed the instruction of Microsoft MSDN. But the following code incorrect run.
Can you help me on it ?
Thanks a lot for your reply.
Tuan
PS : This is my code
extern "C" BOOL PASCAL EXPORT VehicleChange()
{
AFX_MANAGE_STATE(AfxGetStaticModuleState());
CDaoDatabase* connData;
try{
connData = new CDaoDatabase ;
if(connData->IsOpen()) {
AfxMessageBox("The connection has been openned");
}else{
CString strConnect= "ODBC;DSN=FieldTrip;UID=;PWD=;";
connData->Open(_T(""), TRUE,FALSE, strConnect);
}
strSql = "update VehicleInformation set cAacity=11";
connData->Execute(strSql,dbSQLPassThrough);
} catch(CException *e){
connData->Close();
delete connData;
AfxDaoTerm();
return false;
}
AfxMessageBox("success");
connData->Close();
delete connData;
AfxDaoTerm();
return true;
}
|
|
|
|
|
TuanTriTue wrote:
But the following code incorrect run.
Which means what exactly?
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
|
berkeley sockets.
there are enough tutorials here at codeproject.com
modified 12-Sep-18 21:01pm.
|
|
|
|
|
Greeeg wrote:
there are enough tutorials here at codeproject.com
Apparently not in his case since he has already been pointed in that direction. This is about the 5th time he has posted this question.
He is looking like someone trolling to get someone to do his job for him because he is incapable, irresponsible and of course lazy. I would have responded to his post myself but I couldn't find the [get lost] icon
"No matter where you go, there your are." - Buckaroo Banzai
-pete
|
|
|
|
|
I want to launch a .job file in C:\Windows\Task\ directory.
I use system(), WinExec(), ShellExecute(), CreateProcess,
but they all don't work
Is there any other way to implement this function?
Thanks a lot
Jesa
|
|
|
|
|
What is a .job file?
If it has a registered executable associated with the file extension then the process will start if you use ShellExecute() correctly.
"No matter where you go, there your are." - Buckaroo Banzai
-pete
|
|
|
|