The current version of GIMP for Windows has a Wacom bug, if you're using the tablet to paint, you may find that the brush lags heavily.
The bug is identified in libcairo2.
To work around, you can install an older version of GIMP, copy out libcairo-2.dll, libpixman-1.0.dll and libpng15-15.dll and overwrite those in 2.8.14
Bug is here:
https://bugzilla.gnome.org/show_bug.cgi?id=736220
Sunday, October 12, 2014
Saturday, August 9, 2014
Android Studio - Failed to load JVM DLL message
If you have a fresh installation of Android Studio, you may find it not able to start with the error "Failed to load JVM DLL" dialog; despite having a proper JDK and JAVA_HOME installed.
You will need to install Visual C++ 2010 x64 runtime found at:
http://www.microsoft.com/en-us/download/confirmation.aspx?id=14632
That should resolve the launcher problem.
Saturday, July 19, 2014
Workaround for Linux+Wine to fix games screen that is too big for display
If you've set your game(World of Warcraft for me) to run at a lower resolution than your current desktop resolution in Linux, you may find that there will be a viewport showing part of the game and you have to pan around with your mouse.
It's a little ... annoying.
It happens to both my ATI card and Nvidia card running proprietary drivers.
This hasn't always happened. Version 1.0 of Wine for example doesn't exhibit this behaviour.
The workaround is a little clunky; before running the game, use xrandr to check the available modes and then use xrandr to set the game resolution
e.g. launching a terminal and running xrandr:
chocobo:~$ xrandr
Screen 0: minimum 8 x 8, current 1920 x 1080, maximum 16384 x 16384
DVI-I-0 disconnected (normal left inverted right x axis y axis)
VGA-0 disconnected (normal left inverted right x axis y axis)
DVI-I-1 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 477mm x 268mm
1920x1080 60.0*+
1680x1050 60.0
1280x1024 75.0 60.0
1152x864 75.0
1024x768 75.0 60.0
800x600 75.0 60.3
640x480 75.0 59.9
HDMI-0 disconnected (normal left inverted right x axis y axis)
It shows DVI-I-1 connected on my setup, so if my game runs at 1024X768, I'll run the command
xrandr --output DVI-I-1 --mode 1024x768
The desktop will resize to this resolution.
Start your Wine game. It should fit the viewport on your monitor.
Once you exit, set the resolution back to the default desktop setting:
xrandr --output DVI-I-1 --mode 1920x1080
It's a little ... annoying.
It happens to both my ATI card and Nvidia card running proprietary drivers.
This hasn't always happened. Version 1.0 of Wine for example doesn't exhibit this behaviour.
The workaround is a little clunky; before running the game, use xrandr to check the available modes and then use xrandr to set the game resolution
e.g. launching a terminal and running xrandr:
chocobo:~$ xrandr
Screen 0: minimum 8 x 8, current 1920 x 1080, maximum 16384 x 16384
DVI-I-0 disconnected (normal left inverted right x axis y axis)
VGA-0 disconnected (normal left inverted right x axis y axis)
DVI-I-1 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 477mm x 268mm
1920x1080 60.0*+
1680x1050 60.0
1280x1024 75.0 60.0
1152x864 75.0
1024x768 75.0 60.0
800x600 75.0 60.3
640x480 75.0 59.9
HDMI-0 disconnected (normal left inverted right x axis y axis)
xrandr --output DVI-I-1 --mode 1024x768
The desktop will resize to this resolution.
Start your Wine game. It should fit the viewport on your monitor.
Once you exit, set the resolution back to the default desktop setting:
xrandr --output DVI-I-1 --mode 1920x1080
Tuesday, July 15, 2014
2D Maze generation: Java code using Growing Tree algorithmn
Ported the maze generation Python code found in
http://pcg.wikidot.com/pcg-algorithm:maze to Java as a coding exercise.
""You are in a maze of twisty little passages, all alike."
-Adventure"
http://pcg.wikidot.com/pcg-algorithm:maze to Java as a coding exercise.
""You are in a maze of twisty little passages, all alike."
-Adventure"
Sunday, July 6, 2014
Updating Rift to use Glyph Launcher on Wine
From July onwards, Rift game will be launched from the Glyph Launcher.
If you are using Wine to run Rift, the Rift Launcher will attempt to install Glyph and may crash out. The fix is quite simple:
Set Wine to emulate XP. The installer will run successfully. I did not have any luck using Vista as suggested by some.
Add a new shortcut to the GlyphClient.exe found in C:\Program Files\Glyph\GlyphClient.exe to your PlayOnLinux drive and launch it.
It should find Rift and you can go ahead and patch or play it!
If you are using Wine to run Rift, the Rift Launcher will attempt to install Glyph and may crash out. The fix is quite simple:
Set Wine to emulate XP. The installer will run successfully. I did not have any luck using Vista as suggested by some.
Add a new shortcut to the GlyphClient.exe found in C:\Program Files\Glyph\GlyphClient.exe to your PlayOnLinux drive and launch it.
It should find Rift and you can go ahead and patch or play it!
Thursday, June 19, 2014
The shy Ion-Delete-Button in Ionic Framework
I wanted to put a delete button beside the items of my list so my code was like:
<div ng-app="jsApp">
<div ng-controller="Ctrl1">
<ion-content>
<ion-list >
<ion-item>
<ion-delete-button class="ion-minus-circled"></ion-delete-button>Hello, list item!</ion-item>
</ion-list>
</ion-content>
</div>
</div>
Hmm.. where's the delete button? Turns out you had to use show-delete="1" directive in the
<div ng-app="jsApp">
<div ng-controller="Ctrl1">
<ion-content>
<ion-list show-delete="1" >
<ion-item>
<ion-delete-button class="ion-minus-circled"></ion-delete-button>Hello, list item!</ion-item>
</ion-list>
</ion-content>
</div>
</div>
the source code http://jsfiddle.net/rebooting/5BSNE/
That being said I enjoyed using Ionic Framework a lot, it's a very clean framework.
Wednesday, June 18, 2014
Stop command from being commited to BASH History
I haven't seen this in the older bash environments before so I guess it must be fairly recent. To prevent commands from being committed to history, simply add a space in front of the command.
Couldn't be more simpler!
Monday, June 16, 2014
Golang: Serving static content using Gorilla
Using the identical directive from ServeMux "http.Handle("/static/", http.FileServer(http.Dir("./static/")))" for Gorilla to serve static files wasn't working - the directory listing works but clicking on any of the files listed would produce a 404.
There seems to be two ways to configure the mux to serve static content in Gorilla Mux(highlighted in blue)
There seems to be two ways to configure the mux to serve static content in Gorilla Mux(highlighted in blue)
package main
import (
"github.com/gorilla/mux"
"net/http"
)
func main() {
r := mux.NewRouter()
r.HandleFunc("/", HomeHandler)
//This won't work
//http.Handle("/static/", http.FileServer(http.Dir("./static/")))
//These will work
//first alternative
http.Handle("/static/", http.StripPrefix("/static/", http.FileServer(http.Dir("static"))))
//second alternative
r.PathPrefix("/images/").Handler(http.StripPrefix("/images/",
http.FileServer(http.Dir("images/"))))
http.Handle("/", r)
http.ListenAndServe(":3000", nil)
}
func HomeHandler(rw http.ResponseWriter, req *http.Request) {
rw.Write([]byte("You are at /"))
}
Thursday, June 12, 2014
Misplaced semiconlon and debugging fun in Javascript
This is frustrating and funny at the same time. I've been stuck at this simple condition statement wondering my nulled variable didn't check out true ... for about 5 minutes.
Turns out I totally missed ';' at the end of the if statement, which ended the condition and executed the next block of code anyway.
listview_tasks=null;
...
if(!listview_tasks);
{
Ti.API.info("why am I here?");
}
Argh.
I blame the tiny font I'm using on my IDE.
Time for a break me thinks.
Saturday, May 24, 2014
WinAuth and Wine on Ubuntu 14.04
Didn't see much information on WinAuth working via wine so I was surprised to find out how simple it was to get it working in Ubuntu using PlayOnLinux (4.2.2)
Select New.
I'm using the Wine 1.7.15 (32bits).
Call it "Winauth".
Once the step is done, go back to the configuration window and click on "Install Component", select dotnet40 and install.
Once done, open a terminal and copy your Winauth.exe and if you have winauth.xml from your windows directory, copy that too:
$ cp WinAuth.exe ~/.PlayOnLinux/wineprefix/Winauth/drive_c
$ cp winauth.xml ~/.PlayOnLinux/wineprefix/Winauth/drive_c
Go back to the configuration window, making sure that Winauth drive is selected, click "Make a new shortcut from this virtual drive".
Select New.
Select 32 bits Windows installation.
I'm using the Wine 1.7.15 (32bits).
Call it "Winauth".
Once the step is done, go back to the configuration window and click on "Install Component", select dotnet40 and install.
Once done, open a terminal and copy your Winauth.exe and if you have winauth.xml from your windows directory, copy that too:
$ cp WinAuth.exe ~/.PlayOnLinux/wineprefix/Winauth/drive_c
$ cp winauth.xml ~/.PlayOnLinux/wineprefix/Winauth/drive_c
Go back to the configuration window, making sure that Winauth drive is selected, click "Make a new shortcut from this virtual drive".
Click Browse.
You'll be able to find Winauth.exe in the window that shows up. Click Open and once done, exit the configuration window. You should have a shortcut on the desktop as well..
Here it is :)
Friday, May 23, 2014
PlayOnLinux and Diablo 3 ROS: Get pass that "Retrieving Hero List" bug!
PlayOnLinux is a welcomed tool to make Wine configuration fairly painless. The default D3 installation option works, however playing the game with the default options won't work. The game is rendered very slowly and has choppy audio and gets stuck on "Retrieving Hero List"
This is how I fixed it( Ubuntu 14.04 and fglrx drivers):
Highlight "Diablo III", Click on "Configure" on PlayOnLinux toolbar and add "-opengl" in Arguments.
The frame rate should be a lot better now but you will be stuck at "Retrieving Hero List..."
On Ubuntu desktop, selected the Diablo III shortcut placed by PlayOnLinux and edit it to include "setarch i386 -3 " prefix in Command textbox:
The game should work smoothly now.
This is how I fixed it( Ubuntu 14.04 and fglrx drivers):
Highlight "Diablo III", Click on "Configure" on PlayOnLinux toolbar and add "-opengl" in Arguments.
The frame rate should be a lot better now but you will be stuck at "Retrieving Hero List..."
On Ubuntu desktop, selected the Diablo III shortcut placed by PlayOnLinux and edit it to include "setarch i386 -3 " prefix in Command textbox:
Wednesday, May 21, 2014
Steam, Linux and Segmentation fault
My steam deb installation on Kubuntu 14.04 failed while it was trying to start. When I ran the program from the control panel , it showed that it crashed out with a segmentation fault.
Turns out that the issue was attributed to the proprietary drivers I was using( in this case AMD's fglrx). Setting the drivers to the Xorg's drivers and re-run steam worked.
Turns out that the issue was attributed to the proprietary drivers I was using( in this case AMD's fglrx). Setting the drivers to the Xorg's drivers and re-run steam worked.
Tuesday, May 13, 2014
Gigabyte H87 D3H : Not stable or bootable sometimes, but fixed
I got a Gigabyte H87-D3H and a Haswell processor. What adventures I had with it.
Symptoms: With the old PC10600 16gb RAM The box just won't boot sometimes, or would start displaying pixel corruption in the BIOS screen, or hang randomly.
When you get a board fresh from the store together with a new CPU, you would expect the board to boot up just nice right? Apparently not in this case:
The box booted without display. LCD monitor just went to sleep upon finding no signal.
The tedious troubleshooting proceeded, swapping out card to run the native HD4400 display, and disconnecting hard drive and RAM.
The configuration that finally worked for me was when I had one or two sticks of RAM in the board(I had 4X4GB sticks). System ran stable for 2 weeks.
I had some time today since it is a public holiday, so I swapped 2X8Gb cosair kit ram from the Win8 box...and the box booted without display. Only one stick at any slot will work. Great.
Started poking around the BIOS to see if there's any RAM settings that wasn't out of the box when I noticed that the BIOS was 2 revisions and the new one "Support New 4th Generation Intel Core Processors"
Patched it and now it seems to be perfectly happy to take the all RAM sticks. Hello Xubuntu( and all the Wine games).
Troubleshooting PCs are only fun when all you have is time.
Symptoms: With the old PC10600 16gb RAM The box just won't boot sometimes, or would start displaying pixel corruption in the BIOS screen, or hang randomly.
The box booted without display. LCD monitor just went to sleep upon finding no signal.
The tedious troubleshooting proceeded, swapping out card to run the native HD4400 display, and disconnecting hard drive and RAM.
The configuration that finally worked for me was when I had one or two sticks of RAM in the board(I had 4X4GB sticks). System ran stable for 2 weeks.
I had some time today since it is a public holiday, so I swapped 2X8Gb cosair kit ram from the Win8 box...and the box booted without display. Only one stick at any slot will work. Great.
Started poking around the BIOS to see if there's any RAM settings that wasn't out of the box when I noticed that the BIOS was 2 revisions and the new one "Support New 4th Generation Intel Core Processors"
Patched it and now it seems to be perfectly happy to take the all RAM sticks. Hello Xubuntu( and all the Wine games).
Troubleshooting PCs are only fun when all you have is time.
Saturday, May 10, 2014
Disable autocompletion of braces, strings and parentheses in Eclipse
Autocompletion of braces and quotes may be productivity gain for lots of people, that's why Eclipse has that settings on by default right? I found that this feature is breaks my coding flow.. and thankfully there is a way to turn it off easily.
Access Preferences (Alt+,/Eclipse->Preferences in OSX or Window->Preferences in others
Type braces into the text search and disable in Java->Editor->Typing or Javascript->Editor->Typing depending on what source code you're working on.
Uncheck the items under "Automatically close"
Eclipse cannot start
I have a couple of projects in Eclipse that I was importing and deleting. I'm not sure if that caused the symptom to appear when I relaunched Eclipse. Had an error messsage that reads "An error had occured. Please see the log file".
The fix? Navigate via command line and issue "eclipse -clean", then relaunch.
Thursday, May 8, 2014
Rift, PlayOnMac - Update
Just a little update to the previous post on Rift + Wine(http://workinginavirtualspace.blogspot.sg/2014/05/rift-and-wine.html)
.. Rift won't work unless Wine is set up to emulate a virtual desktop.
Enjoy patch 2.7!
.. Rift won't work unless Wine is set up to emulate a virtual desktop.
Enjoy patch 2.7!
SailsJS, Passport and Social Auth
There is Git ready to go example of Sails + Passport JS social authentication for Github, Google+, Facebook and Twitter. I've successfully set up Facebook auth and I suppose the rest will work just as well.
A point to note for Facebook call backs when you see this:
"Given URL is not allowed by the Application configuration.: One or more of the given URLs is not allowed by the App's settings. It must match the Website URL or Canvas URL, or the domain must be a subdomain of one of the App's domains."
On Facebook's dev app page where you created the app, go to Settings->Advanced, enter the callback URL and save.
https://github.com/stefanbuck/sails-social-auth-example/tree/sails_0.10
A point to note for Facebook call backs when you see this:
"Given URL is not allowed by the Application configuration.: One or more of the given URLs is not allowed by the App's settings. It must match the Website URL or Canvas URL, or the domain must be a subdomain of one of the App's domains."
On Facebook's dev app page where you created the app, go to Settings->Advanced, enter the callback URL and save.
https://github.com/stefanbuck/sails-social-auth-example/tree/sails_0.10
Wednesday, May 7, 2014
Fatal Signal 11 , LibGDX 1.0 and GenyMotion
I was encountering the issue on simple libgdx programs crashing out on GenyMotion vm with similar messages like
"Fatal signal 11 (SIGSEGV) at 0x97281008 (code=2), thread 2496 (Thread-183)"
which seems to be caused by any drawing calls... isolated each call and still had the same issue. Program will just crash out with signal 11 after a while.
Turns out the quick fix is to have vmSafeMode in AndroidManifest.xml.
"Fatal signal 11 (SIGSEGV) at 0x97281008 (code=2), thread 2496 (Thread-183)"
which seems to be caused by any drawing calls... isolated each call and still had the same issue. Program will just crash out with signal 11 after a while.
Turns out the quick fix is to have vmSafeMode in AndroidManifest.xml.
<application
android:allowBackup="true"
android:vmSafeMode="True"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/GdxTheme" >
Sunday, May 4, 2014
How to develop with Titanium SDK and Genymotion in OSX
I was puzzled why Titanium SDK wouldn't detect a Genymotion VM even though I've done a ADB connect and "adb devices" can list the device. That is how I debug my android setup in Windows( it's slightly different as the IDE is on a separate network - will cover in the upcoming post).
Turns out that for Mac, if you're running Titanium SDK and GenyMotion all on the same machine, you need to launch a terminal and issue
ti config genymotion.enabled true
Refresh the devices and you will find Genymotion vms listed in the Android Emulator group.
Strange... it's listed differently from my Windows setup (appears as a device).
Thursday, May 1, 2014
OSX Rift and WINE
Rift doesn't have a native client on OSX. Oh well.
I didn't get very far with WineSkin so I thought I'll try PlayOnMac instead. I was using PlayOnLinux when I was using Ubuntu previously.
Install PlayOnMac 4.2.2 (http://www.playonmac.com/en/download.html)
Using PlayOnMac , pull the latest wine binary for POL.(Tools->Manage Wine Versions)
Installed VCRun2005, VCRun2008 and d3dx9
Set the display settings to
GLSL Support : Enabled
Direct Draw Render: OpenGL
Offscreen Rendering Mode: FBO
Strict Draw Ordering: Enabled
I had no luck launching the installer found on the site( it worked in WineSkin hours before however).
I used this patcher instead..
http://update2.triongames.com/patcher/public/Rift_LIVE_Patcher_setup.exe
The installer will run and exit, run it again to patch the patcher(you may encounter a few more crashes but it should work in the end)
The final shortcut installed should be the main launcher for the client.
I didn't get very far with WineSkin so I thought I'll try PlayOnMac instead. I was using PlayOnLinux when I was using Ubuntu previously.
Install PlayOnMac 4.2.2 (http://www.playonmac.com/en/download.html)
Using PlayOnMac , pull the latest wine binary for POL.(Tools->Manage Wine Versions)
Installed VCRun2005, VCRun2008 and d3dx9
Set the display settings to
GLSL Support : Enabled
Direct Draw Render: OpenGL
Offscreen Rendering Mode: FBO
Strict Draw Ordering: Enabled
I had no luck launching the installer found on the site( it worked in WineSkin hours before however).
I used this patcher instead..
http://update2.triongames.com/patcher/public/Rift_LIVE_Patcher_setup.exe
The installer will run and exit, run it again to patch the patcher(you may encounter a few more crashes but it should work in the end)
The final shortcut installed should be the main launcher for the client.
Java development and OSX
During my app development on OSX, the somewhat strange Java situation surfaced with some of the products.
Titanium SDK needs Java 6 to start, Java 1.7 won't do or the IDE will throw an error message. This means the Apple 1.6 version is needed, if you have Oracle JDK installed, you will need to download Java 6 from Apple's site:
Java for OS X 2013-005
http://support.apple.com/kb/DL1572?viewlocale=en_USIntelliJ runs on Java 1.6, however LibGDX requires Java 7. Importing Gradle project will fail with a RoboVM error. Fortunately there is a way to force IntelliJ to use Java 7 runtime.
http://www.gamefromscratch.com/post/2014/04/03/Troubleshooting-IntelliJLibGDXRoboVMGradle-issues-on-Mac-OS.aspx
Wednesday, April 30, 2014
Setting JAVA_HOME for OSX Mavericks
I have a copy of Oracle JDK 7 installed in my system.
The fix:
To get the correct path, you will need to execute /usr/libexec/java_home to obtain the path.
To automatically set JAVA_HOME in terminal every time, append
export JAVA_HOME=`/usr/libexec/java_home`
to the end of ~/.bash_profile
You should be able to execute mvn in a new terminal.
Friday, April 25, 2014
Activate Go Syntax highlighting for VIM in Ubuntu 14.04
This seems to be the shortest step to enable Go's syntax highlighting out of the box on Ubuntu 14.04 server.
I haven't tried the desktop edition but it should be similar.
Install vim-syntax-go
sudo apt-get install vim-syntax-go
Create the .vim directory in your home directory
mkdir .vim
mkdir ~/.vim/syntax
cp /usr/share/vim/addons/syntax/go.vim ~/.vim/syntax/
I haven't tried the desktop edition but it should be similar.
Install vim-syntax-go
sudo apt-get install vim-syntax-go
Create the .vim directory in your home directory
mkdir .vim
mkdir ~/.vim/syntax
cp /usr/share/vim/addons/syntax/go.vim ~/.vim/syntax/
mkdir ~/.vim/ftdetect
cp /usr/share/vim/addons/ftdetect/gofiletype.vim ~/.vim/ftdetect/
Saturday, January 18, 2014
PaintTool SAI and Windows 8.1
Updated PC to Window 8.1 and found that PaintTool SAI wouldn't start without UAC kicking in no matter what I changes I make to the NTFS permissions..
Found the solution for it via http://nerdanswer.com/answer.php?q=359258
Create a batch file :
set __COMPAT_LAYER=RUNASINVOKER
start .sai.exe
as a workaround.
Found the solution for it via http://nerdanswer.com/answer.php?q=359258
Create a batch file :
set __COMPAT_LAYER=RUNASINVOKER
start .sai.exe
as a workaround.
Subscribe to:
Posts (Atom)