15,552 Topics

Member Avatar for
Member Avatar for ammukj

hai i want to track a particular frame from real time webcam video and then use it to simulate mouse movements.can anybody know how to get coordinates from tracking and how it can be integrated with mouse coordinates?

Member Avatar for myk45
0
36
Member Avatar for basukinjal

Suppose we have two array inorder and preorder containing the elements in the said format. Using these two arrays how can i generate the binary tree?? Any help on the algorithm to be followed will be highly appreciated. For eg: inorder is : 2 3 4 5 6 7 8 …

Member Avatar for xinhedanti
0
512
Member Avatar for waqarafridi

Hello All I am Posting after a very Long time because of Having a problem :) The Problem is I want to Convert a String on UNKNOWN size to character array. Explanation: I have a file in JAVA that sends some string through JNI, I collect that String in C. …

Member Avatar for waqarafridi
0
5K
Member Avatar for charchar88

I'm using gcc to compile and I need to be able to run it by doing ./test 7 10 + this is part an attempt of a Reverse Polish Notation calculator for one of my computer classes. My program works if I put it in quotes passing the sequence in …

Member Avatar for charchar88
0
2K
Member Avatar for swatipoddar

hi, i downloaded the existing twofish algorithm from bruce schiener's website but i am having trouble compiling it i.e making it run. can some one plz help me.

Member Avatar for swatipoddar
0
561
Member Avatar for Prisms

Hey everyone I was wondering if anyone had any tips or methods for me to better my programming in C. I know I have to practice problems from my book but are there any other ways to better my code writing skrills :D thank you.

Member Avatar for L7Sqr
0
141
Member Avatar for chester1908

Hey all. I'm having a bit of problem with structs. Say we have a struct comprised of some strings and ints.One of the strings is a keycode,which is used for hashing.So my program reads from a file some information,creates a struct and using that keycode it places the struct on …

Member Avatar for Ancient Dragon
0
194
Member Avatar for charchar88

I'm new at C coming from java but I'm learning it in one of my college classes and so far it's a nightmare anytime I write a program with it :'(. I'm writing a Reverse polish notation calculator and I'm using gcc as my compiler. I want to be able …

Member Avatar for WaltP
0
220
Member Avatar for dalk8978

This is a two part program that I i had someone help me do but I need it transfered to simple c (printf and scanf ). If someone could help that would be great. 1) //Header file section #include<iostream> #include<cctype> using namespace std; void main() { char character[6],ch; int count=0; …

Member Avatar for WaltP
0
181
Member Avatar for zychos

Doing an assignment to create a struct that holds keywords and then is used with a binary search to counter the total keywords in a program. Below is my code and below it is the errors i get when I attempt to compile it. First question is what is wrong …

Member Avatar for zychos
0
432
Member Avatar for vedro-compota

Hi friends! What is the difference between these two definitions of variables? [CODE]const char *msg; char* const msg;[/CODE] thanks in advance)

Member Avatar for vedro-compota
0
101
Member Avatar for murderotica

Is there a usb_reset() version in Winusb? I've been researching what function to use in order to reset the usb device. I tried WinUsb_SetPipePolicy and passed RESET_PIPE_ON_RESUME as the policy type but I think this is not the right function that corresponds to the usb_reset() of libusb which resets the …

0
80
Member Avatar for vedro-compota

Hi mates!) If somebody can - please explain me - what does mean "[U]the lowest[/U]" in this context - [QUOTE]The open() function shall return a file descriptor for the named file that is [B][U]the lowest[/U][/B] file descriptor not currently open for that process.[/QUOTE] the QUOTE is from here - [URL="http://pubs.opengroup.org/onlinepubs/009695399/functions/open.html"]http://pubs.opengroup.org/onlinepubs/[/URL] …

Member Avatar for vedro-compota
0
181
Member Avatar for coding101

How can I convert an unsigned int to a signed int using only bitwise operators?

Member Avatar for WaltP
0
49
Member Avatar for TinhornAdeniyi

What is wrong with my fread() [CODE]#include<stdlib.h> #include<stdio.h> #include<math.h> double stdDev(double avg, double x[]) { double stdDeviation; double diff; double Sqdiff; double sum=0; int i; for(i = 0; i<50; i++) { diff=x[i]-avg; Sqdiff=pow(diff,2); sum+=Sqdiff; } stdDeviation=sum/avg; return sqrt(stdDeviation); } double maximum(double x[]) { int i; double max; max=0; for( i …

Member Avatar for WaltP
0
99
Member Avatar for rockerjhr

globals.h [CODE] #ifndef _globals #define _globals #define DATA( L ) ( ( L ) -> datapointer ) #define NEXT( L ) ( ( L ) -> next ) typedef enum { OK, ERROR } status ; typedef enum { FALSE = 0 , TRUE=1 } bool ; typedef void *generic_ptr …

Member Avatar for rockerjhr
0
139
Member Avatar for manofhouse

Program is suppose to convert binary to hex.. it says that i need a class/struct/union to the left of ".substr" but im pretty sure convert should be working.. [CODE]#include <iostream> #include <string> using namespace std; int main () { string convert [8]; string bin[16]= {"0000", "0001","0010","0011","0100","0101","0110","0111","1000","1001","1010","1011","1100","1101","1110","1111"}; string hex[16]= { "0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F"}; …

Member Avatar for Tomi1988
0
418
Member Avatar for Sheldon.

I really need to find out the correct syntax for passing a two dimensional array.

Member Avatar for Sheldon.
-1
71
Member Avatar for darkbreaker

I am developing a network chat application, I am using Winapi, my main window is a dialog (created from a .rc file). I am looking into a way of doing an text box where my outuput text can be like this: [QUOTE] [COLOR="Green"]Welcome to ##### chat server![/COLOR] [COLOR="Red"]Person1[/COLOR] says: Hi …

Member Avatar for darkbreaker
0
272
Member Avatar for TinhornAdeniyi

[CODE]void maximum(double *max, double x[]) { int i; for( i = 0; i<100; i++) { if(max < x[i]) max=x[i]; } }[/CODE] Why isnt this working Im probrably missing one syntaz that i cant think of at the moment Thank u

Member Avatar for TinhornAdeniyi
0
103
Member Avatar for dashure

if anybody can help me with this code...plz [CODE]#define _CRT_SECURE_NO_WARNINGS #include <stdio.h> #include <stdlib.h> #include <string.h> void * scrambleArr(void * arr, int numElem, int elemSize,int (*func)(void*)); int func(void *x); void main( ) { int a[7]={1,2,3,4,5,6,7}; int i; int *p = NULL; p = scrambleArr(a, 7, sizeof(int),func); for (i = 0; …

Member Avatar for dashure
0
125
Member Avatar for Protoroll

I have to read in a file and do dot product calculations on two arrays but I get an error whenever I try to run it. Here is my code, [CODE]#include <stdio.h> #include <stdlib.h> #include <string.h> #include <math.h> int main() { FILE* input; FILE* output; int product=0; int length=0; int* …

Member Avatar for Protoroll
0
241
Member Avatar for acpr

i'm working on this program to 'read an array(int and float values) from a file and then print it out on the screen'....the i/p data file is looks like this #lat lon B s date X v 60.97 56.10 26.50 33.389 03 07 02 24.00 4 60.36 53.58 28.90 35.731 …

Member Avatar for acpr
0
208
Member Avatar for nadleeh

how can i parse between blank lines in a file to separate paragraphs between the white lines?

Member Avatar for abhimanipal
0
75
Member Avatar for aamira_s

This program is to count the number of words,vowels and consonants of a string.Here is my code.Please post your comment.I do not know whether I need to change anything. [CODE]#include <stdio.h> int main() { char a,b =' '; int vowel=0,c=0,count=0; printf("Please press '*' to terminate.\n\n"); while(scanf("%c",&a)==1) { if(a=='*') break; else …

Member Avatar for abhimanipal
0
163
Member Avatar for aamira_s

this is a simple code to test whether a number is prime or not...i dont know y it is taking this much time to execute...can ne1 tell where m mistaking?? heres my code [CODE] #include<stdio.h> #include<math.h> int main() { int a,n,prime,l=2; printf("Please enter a positive integer.\n"); printf("To end the program …

Member Avatar for Adak
0
163
Member Avatar for shazzy99

[COLOR="Green"]Trying to take input from user, put it in array and do the sorting[/COLOR] The code is: [CODE] #include <stdio.h> #include <conio.h> #include <stdlib.h> class Sort { static int array[5]; static int index; static int i; public: void insert(int num) { array[index] = num; index++; } int sortarr(const void *x, …

Member Avatar for Narue
0
183
Member Avatar for rockerjhr

radixsort.c [CODE]/**************************************************************************************/ /* Radix Sort of integers numbers using polymorphic linked lists. */ /**************************************************************************************/ #include <stdio.h> #include "list.h" #include <stdlib.h> #include "numberinterface.h" #include <math.h> void static refill( int A[] , list Bins[] ) ; int static getdigit( int number, int position ) ; int main( int argc, char *argv[] ) …

Member Avatar for Ancient Dragon
0
237
Member Avatar for spark69

Hello, I have two very simple questions. 1. I want to use fgets(text, MAX_WORDS, stdin) to read in a string file, where my array is text[MAX_WORDS]. But is there a way to make stdin a pointer instead to a 2nd array which can be a buffer? 2.Whats the difference between …

Member Avatar for Narue
0
584
Member Avatar for markfw

Hi. When I was looking at the header files of c library such as malloc.h, I saw that it defines some functions inside the struct (Function Pointer) and other functions outside, so my question is, why sometimes people defining function inside the struct and sometimes outside? Thanks -- Mark

Member Avatar for rubberman
0
83

The End.