RSS

unresolved external symbol _clReleaseContext@4

When tesging an OpenCL program in 64bit windows, Visual Studio 2010, building the program generates below error:

error LNK2019: unresolved external symbol _clReleaseContext@4 referenced in function
error LNK2019: unresolved external symbol _clGetDeviceInfo@20 referenced in function
error LNK2019: unresolved external symbol _clGetContextInfo@20 referenced in function
error LNK2019: unresolved external symbol _clCreateContextFromType@24 referenced 
error LNK2019: unresolved external symbol _clGetPlatformIDs@12 referenced in function

Although I have added the necessary Include, Lib directory and the needed lib files to the projects, yet it still does not work, see below:

image image

image

Finally when I change the program configuration from x86 to x64, and rebuild, it works!

image

Happy coding!

 
Leave a comment

Posted by on February 5, 2012 in Dotnet/C#, Programming

 

Git: make an existing local branch track a remote branch

If a branch is not created, it is well know to use below command:

git checkout –track –b SomeBranch remote/SomeBranch

However if you have ever created a local branch using

git branch SomeBranch

You can use below command to hook the local with the remote branch

git branch  –set-upstream SomeBranch remote/SomeBranch

 
Leave a comment

Posted by on February 3, 2012 in General

 

Using git command with proxy network settings

Using git bash when a proxy is required is not as easy as is expected, below is the procedures to setup this:

1. in the command prompt, type:

git config –global http.proxy http://user:password@proxy-hk1.someproxy.co.uk:80

where the uer and password strings are self-explantory

2. after setting the proxy, you can see if this configuration really takes effect by typing in the command:

git config –get –global http.proxy

3. Once this is done, you might try:

git pull origin master

however it won’t work!

4. Replace the origin with the github URL:


git pull http://github.com/YourGitHubURLHere master

it will work now!  Note that you might be prompted to input GitHub user name and password as well.



Cheers.

 
1 Comment

Posted by on February 3, 2012 in General

 

Hoops 19 Form does not show in VisualStudio 2010

I have udpated Hoops SDK from v17 to v19, and my previous C# Winform application, which runs pretty well in v17, fail to start in v19. Debugging into the code reveals the below exception:

image

Read the rest of this entry »

 
Leave a comment

Posted by on December 26, 2011 in General

 

ofEnableAlphaBlending()/ofSetVerticalSync(true) results in program crashing: access violation and troubleshooting

In a recent project using openFramework, the program crashes on startup. Debugging into the program shows that the program halts when the functions ofEnableAlphaBlending() or ofSetVerticalSync(true); is called. A Google searching shows that this is most probably due to the fact that OpenGL driver of the display adapter is too low, e.g. OpenGL 1.1 is used, whereas OpenGL 1.3 or above is expected to make the program run smoothly.

To trouble shoot this, update the display driver to support OpenGL 1.3 or above:

Read the rest of this entry »

 
Leave a comment

Posted by on December 17, 2011 in openFramework

 

A brief list of git commands

 

git fetch origin
(origin is the serve alias)
Looks up which server is origin; –>
fetches any data you don’t have—>
update local data base –>
moving the origin/master pointer to up-to-date position

image   image

The above figures are copied from Git Pro book, see here for details.

Read the rest of this entry »

 
Leave a comment

Posted by on December 11, 2011 in Programming

 

Git Command explained with snapshots (II)

Continuing the previous article, now let’s apply some modifications on the “SomeText.txt”, but do NOT save it at the moment! Then run the command “git diff”

image

image

Read the rest of this entry »

 
1 Comment

Posted by on December 10, 2011 in General

 

Git Command explained with snapshots (I)

The very beginning step is probably creating/selecting a folder (e.g. C:\_Test) where to keep your source code. Now this folder is just a common folder, and it is not a Git repository yet. To let Git know this, use the command: “git init

image 

image
The folder before “git init”

Read the rest of this entry »

 
1 Comment

Posted by on December 10, 2011 in Programming

 

Diable Fn key of Mac keyboard for Bootcamp-based Windows system

In a recent project, we are required to deploy our application in Windows platform, and we then installed Windows 7 using Bootcamp. In the subsequent development using Visual Studio 2010, we frequently use F5 (Run/debug), F12 (Go to definition) and F10 (Step into), but each time, we have to use the combination of Fn + F5, Fn + F12, Fn + F10 etc. to accomplish the desired tasks. One of colleagues Arthur, found the way to solve this, although this is also searchable using Google, but it seems almost all descriptions are not very clear. Below are the detailed procedures with snapshot:

  • In the system try, click the icon Boot Camp;
  • Then click the “Boot Camp Control Panel”;
  • in the “Keyboard” tab, tick the “Use all F1, …”

image  image

Read the rest of this entry »

 
Leave a comment

Posted by on December 5, 2011 in General

 

openFramework in VisualStudio: “error C2001: newline in constant” or “IntelliSense: too many characters in character constant” error

When compiling the examples in the openFramework, if you encounter the below errors:

  • “IntelliSense: too many characters in character constant    …icons.h” or
  • error C2001: newline in constant (see below Fig.1)

imageFig.1

Read the rest of this entry »

 
Leave a comment

Posted by on December 4, 2011 in openFramework

 
 
Follow

Get every new post delivered to your Inbox.