- 博客(21)
- 资源 (13)
- 收藏
- 关注
原创 程序修改思路1
分割完成之后,每点击图像区域,把区域涂色,而且是一种颜色,在结束之后,保存颜色是关键,并能计算,有多少区域被点击,和区域的总面积!以及被点击区域占所有区域的百分比,抓紧时间吧,不能再水了,亲,
2011-07-31 20:51:24 1568
转载 C++中的单例模式
单例模式也称为单件模式、单子模式,可能是使用最广泛的设计模式。其意图是保证一个类仅有一个实例,并提供一个访问它的全局访问点,该实例被所有程序模块共享。有很多地方需要这样的功能模块,如系统的日志输出,GUI应用必须是单鼠标,MODEM的联接需要一条且只需要一条电话线,操作系统只能有
2011-07-29 22:35:00 47696 21
原创 string的部分实现
#include using namespace std;class String{public: String(const char *str = NULL); // 通用构造函数 String(const String &another); // 拷贝构造函数
2011-07-27 21:53:22 2937 6
原创 引用学习
引用就是某个目标变量的“别名”(alias),对应用的操作与对变量直接操作效果完全相同。申明一个引用的时候,切记要对其进行初始化。引用声明完毕后,相当于目标变量名有两个名称,即该目标原名称和引用名,不能再把该引用名作为其他变量名的别名。声明一个引用,不是新定义了一个变量,它只表示
2011-07-27 17:01:12 1613
转载 C++中new和delete学习总结
new和delete在C++中特别要重,在此简单总结一下new和delete各种含义。new与operator newC++中有很多语法让人难以理解,如:new operator(操作符,下同)和operator new之间差异,确切的说,应该是new与operator new
2011-07-20 21:25:40 2107
原创 queue C++实现
#include#include class node{public: node():item(),next(NULL){} node(int i):item(i),next(NULL){} int item; node *next;};class queu
2011-07-18 22:40:15 2278
原创 opencv学习1
#include"cv.h"#include "cvaux.h"#include "highgui.h"using namespace std;void PrintMat(CvMat * A){ int i,j; for(i=0;irows;i++) { pr
2011-07-17 11:20:50 816
转载 const使用详解
关于C++中的const关键字的用法非常灵活,而使用const将大大改善程序的健壮性,现将本人的一些体会总结如下,期望对大家有所帮助: 一 const基础 如果const关键字不涉及到指针,我们很好理解,下面是涉及到指针
2011-07-16 11:42:06 771
原创 括号匹配
#include #include using namespace std;template class node{public: node* next; T val; node():next(NULL),val(){}; node(T v):next(NUL
2011-07-13 20:38:12 1008
原创 stack类C++实现
自己写的stack类,功能可能很少,也可能里面很多错误,,但至少我测试的是正确的,;代码奉上:#include using namespace std;template class node{public: node* next; T val; node():ne
2011-07-12 22:36:24 8499 3
原创 分享一个小技巧
不用再满世界找神马真随机数的各种代码,原来excel自带有这个功能:如果想产生3.5到3.8之间的4位小数:只要在第一个空格里输入:=ROUND(0.8+(0.1)*RAND(),4);然后根据需要产生多少随机数,下拉表格就行了,ok!就这么简单!
2011-07-08 19:36:13 927
转载 Jpeg 转bmp
#include "jpeg.h"#include "memory.h"#include "math.h"#include "stdio.h"#include "windows.h"//macro definition#define WIDTHBYTES(i)
2011-07-07 15:43:24 6325 2
转载 string类实现
#include #include using namespace std;class String{public: String(); String(const char * src); String(String & src); ~Str
2011-07-06 15:42:08 1081
转载 The Name Return Value Optimization
I received the following mail the other day in response to my writing that the Visual C++ compiler has [finally!] implemented the
2011-07-06 15:28:24 1606 1
转载 双链表 先学习下
#include class node{public:int value; //value stored in the node node *next; //pointer to next node node
2011-07-04 21:27:21 885
原创 List node
#includeusing namespace std;const int DefaultSize = 100;class List{public: List(); List(List &L); ~List(); void insert(co
2011-07-03 22:33:17 1351
原创 Visual Assist X中文注释提示错误问题
这个Visual Assist X认为中文的注释是拼写错误,解决方法:去掉Visual Assist X Options->Advanced->Underlines的Underline spelling errors in comments and strin
2011-07-03 21:33:03 1341
原创 calculate the length of char*
#include using namespace std;int len(char* str){ int i = 0; while (*str != "/0") { ++i; ++str; } return i;}
2011-07-03 16:43:13 831
转载 Getting Started with Data Structures
I've received a few PM's over the last couple weeks with requests asking how to get started learning data structures. This entry w
2011-07-03 12:01:25 827
原创 List
#includeusing namespace std;const int DefaultSize = 100;class List{public: List(); List(size_t size); List(List &L); ~List(); bool insert(const int); void Clear
2011-07-02 20:31:37 733
原创 knn
knn_light.m % knn_light: K-Nearest Neighbor classification using euclid distance%% [C] = knn_light(data, proto, protoClass, [K])%% Input and output arguments ([]s are optional):% data (mat
2011-07-02 13:48:04 964
Oracle8i_9i数据库基础
2011-12-21
FaceTracking
2011-11-20
Efficient region segmentation through ‘creep-and-merge’
2011-03-06
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人