Quantcast
Channel: Programming – Xinyustudio
Browsing all 284 articles
Browse latest View live

Image may be NSFW.
Clik here to view.

ofEnableAlphaBlending()/ofSetVerticalSync(true) results in program crashing:...

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);...

View Article


Image may be NSFW.
Clik here to view.

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...

View Article


Image may be NSFW.
Clik here to view.

Installing Git-flow in Windows

git-flow is a bunch of Git extensions that makes version control extremely easy. Below is a concise procedure to install it on Windows platform. 1. Download getopt.exe from util-linux package, download...

View Article

Image may be NSFW.
Clik here to view.

10 lines of code: using json in python

1.  import httplib,json2.  url = ‘www.yupoo.com’3.  path = ‘/api/json/api_key=d74aad0331494be468c07f47987b099b&method=yupoo.photos.licenses.getInfo’4.  conn = httplib.HTTPConnection(url)5....

View Article

Image may be NSFW.
Clik here to view.

Manage Google Cloud Storage with Python

Download and install GSUtil. GSUtil is bundled in a single archive named gsutil.zip. Unpack the archive in a convenient location, such as C:\GSUtil, see also...

View Article


Image may be NSFW.
Clik here to view.

Using Python & OpenCV to control WebCam, black window: problem and...

I recently involved in a project to capture images with webcam. I soon found that OpenCV seems to be the best solutions to program in Python. For how to install Python and OpenCV, refer to the link...

View Article

Image may be NSFW.
Clik here to view.

Python Socket example: the simplest example

The python socket component is extremely easy to use, and this simplest example demonstrated its typical use. This is simplest, since both the server and client are the local machine: On the Server...

View Article

Image may be NSFW.
Clik here to view.

C++: Show Full Screen Images in a UI (Part I: Using Nokia Qt)

I was asked to develop a mini-application: just to show a single full screen image to hide some ugly console output. The application supports a command line: FullScreen.exe SomeImage.          The...

View Article


Image may be NSFW.
Clik here to view.

C++: Show Full Screen Images in a UI (Part II: Using Openframework)

One of my colleague recommended me using Openframework to implement the program to show a full screen image. See more details in this previous blog. So I first created an application class...

View Article


Image may be NSFW.
Clik here to view.

fatal error LNK1104: cannot open file ‘PocoFoundation.lib’

When using openframeworks and building the application, occasionally you may encounter the below error: fatal error LNK1104: cannot open file ‘PocoFoundation.lib’ Searching the internet, and there...

View Article

Image may be NSFW.
Clik here to view.

Git: rename a branch locally and remotely

git checkout master git push origin HEAD:newBranchName (1) Create a new branch remotely git branch newBranchName (2) Create a new branch locally git checkout newBranchName (3) Checkout the new branch...

View Article

Image may be NSFW.
Clik here to view.

Setup CGAL in Windows 7: step-by-step tutorial

CGAL (Computational Geometry Algorithms Library) is a useful library for CAD/CAE/CAM users and developers. Below is a step-by-step tutorial on how to install CGAL in your windows system. Download the...

View Article

Image may be NSFW.
Clik here to view.

Setup CGAL in Windows 7 using cmake command line

In my previous post, I discussed building CGAL using cmake-gui option, and in this post, I will demo how to do this from command line cmake: Download Boost. This is a must. It is recommended to...

View Article


Image may be NSFW.
Clik here to view.

Nokia Qt: Add and reference image resources

Right click the left project tree, click “Add New …”                         Select “Qt” in the left panel, and “Qt Resource file” in the right panel In the left project tree, there will be a new *.qrc...

View Article

Image may be NSFW.
Clik here to view.

Troubleshooting: “conq: repository does not exist. fatal: The remote end hung...

In a recent project, suddenly I cannot pull and push, with below error: conq: repository does not exist.fatal: The remote end hung up unexpectedly Googling this indicates that remove and then re-add...

View Article


Image may be NSFW.
Clik here to view.

WPF: Difference of Visibility.Collapsed and Visibility.Hidden

In a recent trial to rename a TreeViewItem in WPF, I added a TextBlock as well as a Hidden TextBox in the Header, so that when in a “rename”, I will toggle of the TextBlock and TextBox’s visibility and...

View Article

Image may be NSFW.
Clik here to view.

Expression Blend 4: cannot see/switch to design view

If you are using Visual Studio 2012 to create a WPF application, and open it in Micosoft Blend 4, it is likely that you can only see the XAML file, but cannot switch to design view. To solve this, in...

View Article


Image may be NSFW.
Clik here to view.

C#: How to get installed Matlab paths and versions

In a recent project, I need get the installed Matlab’s executable path and their versions, and I know that users might not install Matlab in default “C:\Program files\MathWorks\…”. The first solution...

View Article

Image may be NSFW.
Clik here to view.

How to use WPF AvalonWizard control (I)

The AvalonWizard control is a handy WPF wizard control. To use it in your project, follow below procedures: 1. In your project, add a reference to the AvalonWizard assembly. You can right click the...

View Article

Image may be NSFW.
Clik here to view.

How to use WPF AvalonWizard control (II): Adding event handlers

In my previous post, we have discussed on how to get started with AvalonWizard. Yes, we need do sth else to make it work for our project. In this post, I will demonstrate how to add some logic to...

View Article
Browsing all 284 articles
Browse latest View live