CR的代码文本

all for learning about the world
  订阅 订阅  :: 管理

计划缓冲区

Posted on 2010-11-19 13:48  mumuliang  阅读(714)  评论(0编辑  收藏  举报

 

2/11/2015

《JAVA编程思想》

 

 

8/15/2014

c# 扩展方法奇思妙用

http://www.cnblogs.com/ldp615/archive/2009/08/07/1541404.html

 

1/3/2014

_tcsdup(),分配目的串内存空间,然后将源字符串的内容copy到目的串中。(加一句,用完以后记得要free掉目的串的内存)

《C Startup》  http://www.bravegnu.org/gnu-eprog/c-startup.html

 

12/24/2013

删除win7资源管理器左侧导航窗口的收藏夹、库、家庭组以及网络的方法:

1.首先到开始菜单的搜索框输入regedit,然后点击运行搜索到的regedit(也可以在开始菜单--“运行”里面输入regedit,打开“运行”的快捷键是win+R)

2.打开注册表编辑器之后,定位到你需要删除的项目的注册表项位置。

3.在找到你要删除的项的注册表项位置之后,右键单击ShellFolder,选择“权限”,然后选中Administrators,勾选上“完全控制”,确定。然后双击右侧窗格中的Attributes,修改他的值即可实现删除。

各个项目的注册表项的具体位置如下:

收藏夹的位置在: HKEY_CLASSES_ROOT\CLSID\{323CA680-C24D-4099-B94D-446DD2D7249E}\ShellFolder, 双击右侧窗格中的Attributes将a0900100改成a9400100

库的位置在: HKEY_CLASSES_ROOT\CLSID\{031E4825-7B94-4dc3-B131-E946B44C8DD5}\ShellFolder, 双击右侧窗格中的Attributes将b080010d改为b090010d

家庭组的位置在: HKEY_CLASSES_ROOT\CLSID\{B4FB3F98-C1EA-428d-A78A-D1F5659CBA93}\ShellFolder, 双击右侧窗格中的Attributes将b084010c改成b094010c

网络的位置在: HKEY_CLASSES_ROOT\CLSID\{F02C1A0D-BE21-4350-88B0-7367FC96EF3C}\ShellFolder, 双击右侧窗格中的Attributes将b0040064改成b0940064

注意,只需要修改你想删除的项目的就行了,不想删除的就不要动,要删除收藏夹就只修改收藏夹的。

修改之后,不需要注销计算机和重启计算机,只需要到任务管理器的“进程”将explorer结束即,然后在任务管理器的“应用程序”标签选择“新任务”,输入explorer回车即可。

12/6/2013

ObjectARX Main Libraries

  • AcRx Object and Class Management (rxapi.lib)
  • AcDb AutoCAD Database (acdb19.lib)
  • AcGi AutoCAD Graphics Interface (acgiapi.lib)
  • AcGe AutoCAD Geometry Library (acge19.lib)
  • AutoCAD Core Library (accore.lib and ac1st19.lib) 
  • AcUi/AdUi MFC Extension Library  (adui19.lib acui19.lib)
  • Automation (axdb.lib)
  • ads_ Function Set (acad.lib)
  • AutoCAD Facet Modeler (aecmodeler.lib) 
  • AutoCAD Boundary Representation (acbr19.lib, acgex19.lib)

-----

The first parameter of acrxEntryPoint() is a data member of the AcRx class called msg which represents the message sent from the ObjectARX kernel to the application. Refer to the online help for details about the different messages
an ObjectARX application can receive from AutoCAD.

第一句的arx内核和第二句的autocad应该指的是同一方,而第一句的application和第二句的 objectarx application指的都是用VS捯饬出来的那个arx,即那个插件,那个……

--------

Also by default, ObjectARX applications are not MDI aware (again, please refer to the online help for detailed information on the MDI issues). Applications need to register themselves explicitly as being MDI aware using the acrxRegisterAppMDIAware() global function. 

MDI赶脚怪怪的。tips and tech..里面有说ARX不支持多线程。mdi不多线程怎么得了?

 

12/6/2013

ObjectARX API.pptx 中

AutoCAD has a fiber-based architecture

  • see MSDN for more info on fibers
  • fibers are scheduled by AutoCAD
  • they have their own call stack
Application fiber (context):
  • runs windows message loop
  • kicks off a fiber for each document created
Document fibers (context):
  • run commands for the given document

MSDN Fiber:http://msdn.microsoft.com/en-us/library/windows/desktop/ms682661(v=vs.85).aspx


12/4/2013

readarx.chm

《What's in the ObjectARX SDK Documentation Set?》

  • Reference Guide - provides object-oriented C++ programming interfaces for developers to use, customize, and extend AutoCAD software and AutoCAD-based products like AutoCAD® Architecture, AutoCAD® Mechanical, and AutoCAD® Land Desktop software. In addition, it also includes information about how to update existing ObjectARX® applications to work with the most recent release of AutoCAD® in the migration section. In this section you can find information about changes to the syntax and behavior of existing native (C++) APIs.

以为有用,再读一遍发现理解错了。

 

8/2/2012 

AS3 笔记

1. 用setTextFormat方法修改TextField的字体格式,必须在.text有值之后,否则格式不生效;

2. 用defaultTextFormat属性修改TextField的字体格式,没有1.的限制;

3. 脚本修改窗体大小位置要注意两个属性:stage.scaleMode和stage.align;

4. 脚本设置TextField的中文字体,字体名必须是中文字体的对应英文名;

5. 事件对象的updateAfterEvent()方法,意,完成后再一起绘制;

6. 正则表达式中?除了有0或1个含义外,它还可放在+和*之后表示强制使用懒惰性匹配;

7. 正则表达式中:i,ignore忽略大小写; s,dotall开启.匹配换行符\n;x,etended支持扩展正则表达式,即忽略正则中的空格;m,multiline开启$行头^行尾匹配;

8. 正则中,\b匹配单词边界,\B匹配非单词边界。 

 

7/12/2012

 

多核下获取单个CPU利用率

http://blog.csdn.net/JPEXE/article/details/3541270

 

6/29/2012

// toolwindow不出现在任务栏
LONG style = GetWindowLong(g_hWnd, GWL_EXSTYLE);
style |= WS_EX_TOOLWINDOW;//~WS_EX_APPWINDOW;
SetWindowLong(g_hWnd, GWL_EXSTYLE, style);

添加托盘图标 

 

6/25/2012

windows via c/c++ ch15,using virtual memory...? 

#pragma section("mycode", read)  
#pragma data_seg 

__declspec(allocate("segname")) declarator 

 

#pragma data_seg("shared")
volatile LONG g_lInstances = 0;
#pragma deta_seg()
#pragma comment(linker, "/Section:shared, RWS") 

 

 

6/19/2012

Windows核心编程上提到创建IO完成端口的函数CreateIoCompletionPort被设计成要调用两次,

想起前几天也看到DXGI里面也有这样的API,当时还想着说MS真心省事儿,但就是想不起是啥。 

费了阵劲儿翻出来,是IDXGIOutput::GetDisplayModeList

另外还发现了一个ID3D10InfoQueue::GetMessage

记下以备他日蛋疼用。

-------------------------------

线程池中应该有多少线程?标准的经验法是取主机的CPU数量乘以2。 

《CreateThread与_beginthread,内存泄漏为何因》   

 

6/18/2012 

LCID,local id,是一个32位值,用来标识一种语言. API GetThreadLocale得到主调线程的LCID. 

避免使用%s字段类型进行ANSI与Unicode字符串之间的转换。使用MultiByteToWideCharWideCharToMultiByte 

UNICODE和_UNICODE同是非 

IsTextUnicode 

--

HKLM/Software/Microsoft/Windows NT/CurrentVersion/Windows/AppInit_DLLs
指定的DLL会被任何用到User32.dll的所有程序自动加载。

当User32.dll加载的时候,User32.dll的DllMain会收到一个DLL_PROCESS_ATTACH通知,User32在这个时候读取注册表项中的值,调用LoadLibrary加载各个DLL。 

 

6/17/2012

HOOK

http://www.microsoft.com/china/community/program/originalarticles/techdoc/hook.mspx  

WDDM 

http://msdn.microsoft.com/en-us/library/windows/hardware/ff570593(v=vs.85).aspx 

http://msdn.microsoft.com/en-us/library/windows/hardware/ff570595(v=vs.85).aspx 

 

 

 

6/15/2012

DWM 

http://msdn.microsoft.com/en-us/library/windows/desktop/aa969540(v=vs.85).aspx 

http://msdn.microsoft.com/en-us/library/aa969541%28v=vs.85%29.aspx

http://msdn.microsoft.com/en-us/library/aa969538%28v=vs.85%29.aspx 

WARP

http://msdn.microsoft.com/en-us/library/windows/desktop/gg615082(v=vs.85).aspx#removing_the_need_for_custom_software_rasterizers 

XXX

http://www.faqs.org/patents/app/20090102862  

 

 

6/12/2012

the best method to receive high-definition mouse movement data is WM_INPUT

http://msdn.microsoft.com/en-us/library/windows/desktop/ee418864(v=vs.85).aspx  

 

5/31/2012

http://www.director-online.com/dougwiki/index.php?title=Undocumented_Lingo 

 

 

5/23/2012

1/10秒规则,视觉后向,视觉暂留现象,似动现象。 

MSG_DONTROUTE, 要求传输层不要路由数据包

 

5/21/2012

汇编汇编汇编汇编-_- 

挺好的MSR Kinect系列

http://www.cnblogs.com/yangecnu/category/373950.html 

窗口消息处理程序通过拦截WM_SETFOCUS和WM_KILLFOCUS消息来判定它的窗口何时拥有输入焦点 

 

5/14/2012

Di修改代码字体和着色:Edit->Preference->Script

 

5/10/2012

http://vvvv.org/documentation/using-vvvv 

http://www.touchtaiwan.com/exhibitor/factsheet.asp 

所以真正的不分片数据,UDP为1492-28=1464,TCP为1492-40=1452字节。 

---AS3调用C++

1. ExternalInterface

http://help.adobe.com/zh_CN/FlashPlatform/reference/actionscript/3/flash/external/ExternalInterface.html 

2. Alchemy

http://labs.adobe.com/technologies/alchemy/ 

---非阻塞的getch() 

#include <conio.h>
int k = kbhit();
 

 

 

 

2012/2/17 

WebGL基于OpenGL ES 2.0,提供了3D图像的程序接口。它使用HTML5 Canvas并允许利用文档对象模型接口。可利用部分Javascript实现自动内存管理。

说了没用的,不要说。

说了只是为了有人赞同的,不要说。

说了只是为了得瑟,挚友可说。

《House》是部好电视。

 

 

2012/2/1

 

2011/9/22

http://szeliski.org/Book/ 

计算机视觉中的多视图几何 

 

2011/9/6

纹理的新仇旧恨 

 

2011/8/24

对Qt做一全局观 

 

2011/8/23

《windows环境下的多线程编程原理与应用》这本书一直使用的是cout而不是printf,是想激发读者研究cout的不可重入么?

printf是不可重入的。不可重入才会引起线程安全一说。

纤程切换,依然是时间顺序的任务流.没看出特点特色来.待究. 

线程同步算法

互斥量是内核变量,可跨进程;临界段是进程内部的.后者高效. 

 

 2011/8/19 

[Flash CS5 快捷键] 

F8 转换为元件

F9 打开和关闭script窗口

ctrl endter 测试影片 

 

2011/8/18

[Qt]swf播放完毕退出QApplication
[Qt]Qt::WStyle_NoBorder找不到定义

[Qt]make没有生成debug的moc_*.h

 

2011/8/8

allgro PADS ORCAD 

 

2011/7/12

Reflections on Trusting Trust 

http://cm.bell-labs.com/who/ken/trust.html 

 

2011/7/11

OpenCV速成图像处理

如何结合SWF 

 

2011/7/8

二叉树,八叉树——数据结构和算法——离散数学 

 

2011/6/23

OpenGL中向量*矩阵的意义和线性代数的意义

http://duartes.org/gustavo/blog/category/internals/page/2

http://duartes.org/gustavo/blog/category/internals/page/2 

 

2011/6/20

1.GLUT的displayFunc不会刷新数据,除非窗口需要重绘时。

 

2011/6/17

1.如果不使用allocator和errstream参数创建NxPhysicsSDK,cookingclothmesh会失败。原因未知。

2.clothDesc.flags |= NX_CLF_HARDWARE时,情况有点诡异。

3.sceneDesc.simType = NX_SIMULATION_HW;创建成功后,_scene->getSimType()得到的是SW。

4.直接debug重新生成,帧率只能达到50,先release一下,再debug重新生成就60帧了。待究。

 

2011/6/16

函数内部不需保证参数的合法性,合法性应该由调用者保证。

成员函数内部只需要保证使用的成员变量的合法性,无需理会传入参数的合法性。

 

2011/6/14

1.如何使用VBO在PhysX和OSG间传递数据

2.想用Debbuger调试PhysX,connect后把显卡搞停止了。 

 

2011/5/8

Return values and parameters in places where a NULL value is unacceptable are coded with reference (&) syntax. In this case, neither the user nor the SDK checks for NULL values, which do not exist according to C++. 

 

2011/4/29

23球面映射

25变形和从文件中加载物体

26剪裁平面,蒙版,缓存和反射

27影子

28贝塞尔曲面

29Blitter函数

30碰撞检测

31模型加载

32拾取,alpha混合,alpha测试

33加载TGA

36放射性模糊和渲染到纹理RTT

37卡通映射

43FreeType

443D光晕

45顶点缓存

46全屏反走样

47顶点脚本

48轨迹球旋转 

 

2011/4/14

以对象池/制针池管理频繁创建和释放的对象(1频繁程度2内存开销)

 

2011/4/8

对于修改记录状态的成员变量的时机的困惑

基于vector指针不可靠引起的不能使用vector指针传递数据

状态模式C++实现

 

2011/1/13

 

 2010/12/1

《OpenGL编程指南》通读

《OpenGL编程指南》精读

《线性代数》 

 

2010/11/26

《windows程序设计》通读   

链接:一些计算机编程的好书(以C++为主)

        Direct3D Tutrial-01 

 

 2010/11/22 

《MFC深入浅出 》通读 

 visitor模式 

 设计模式总目录

 观察者模式

 迭代器模式 


2010/11/21

1. OSG 2.0以上版本中,已经使用IntersectionVisitor代替了原有的IntersectVisitor类。

 

2010/11/19

《thinking in c++ volume 2》

《inside the c++ object model 》

《windows presentation foundation 程序设计指南》

《编译原理》

《常识》