Showing posts with label Open Source. Show all posts
Showing posts with label Open Source. Show all posts

Monday, March 16, 2015

HarmTrace, or: How I Learned about Cabal Hell and Hated it Ever Since

For a music visualization project I'm trying to get HarmTrace, a haskell library, working. It is what Chordify uses in their backend to detect BPM and Chord changes, and Chordify is great on that.

I did not expect, however, that it would be so hard to install a haskell package. Turns out that the "package manager", Cabal, is famous for breaking dependencies and giving developers hell. To this date I've spent 15 hours on it, and I believe it's very close, but it's been a long and winding journey.

Current progress:

Upstream Mentor (creator of HarmTrace and co-founder of Chordify!) successfully contacted.

Mentor suggestion: Install it in a linux machine, with ghc-7.6.3.

Installation progress:

Mac: using GHC 7.6.3, and custom .cabal file, build gets stuck at hmatrix-gsl-stats-0.2 bug. Someone ran into this as well. His fix didn't work on my machine.

Linux: He suggests using linux for this. Ubuntu was installed in a VirtualBox and I tried to install Haskell-Platform on it. First try with Debian distribution, it bugged out; second try, it ran out of memory after ~5 hours. Oops. Guess I'll try it on my Mint.

The author who ran into hmatrix-gsl-stats problem wrote a post about installing it on Linux. After getting Haskell-platform installed, I'll follow his post for the rest.

Oh, and fragment of a script:

To install from online:
cabal install HarmTrace --with-ghc=ghc-7.6.3 --constraint="HarmTrace-Base==1.1.0.2" --constraint="uu-parsinglib installed" --allow-newer=uu-parsinglib,cabal

To build from local:

cabal configure --with-ghc=ghc-7.6.3
cabal build --with-ghc=ghc-7.6.3
cabal install --with-ghc=ghc-7.6.3

Wednesday, May 28, 2014

Fractionauts v2.0 Post-mortem, and Pixel Art Tips & Resources

We did it! Fractionauts got some great feedbacks. I'm fairly confident that it's the most attractive project during the final presentation.

You can check it out at https://github.com/chrisknepper/xo-fractions-game. Our team used https://github.com/kyung01/xo-fractions-game/ and did a huge fat pull request to merge with the main branch at chrisknepper.

Pixel Art Reskinning

Although I'm no professional artist, making game arts is one of the things I enjoy doing. This time I got the chance to flex that muscle and did a reskin of Fractionauts. There are a few tips and tricks to make such task easier. If you know any, please tell me! Making pixel art is very efficient and fun for 2D games.
The gameplay screen of Fractionauts.

Photoshop Setting

There are many tools you can use to create pixel art, ranging from Photoshop, Illustrator to MSPaint. 
Choose whatever tool you are most familiar with - the arts from Risk of Rain is made in MSPaint and they look FABULOUS.
I do my best work in Photoshop, and there are couple things you can do to make it easier.
  1. In Preference/General, set Image Interpolation to Nearest Neighbor. This will keep the pixels pixelated instead of blurry when the image size is changed.
  2. For the Paint Bucket tool, set Tolerance to 0 and deselect Anti-alias. This makes the bucket™ respect your pixels and does not over-paint it. Or in short, it makes the paint bucket work like the one in MSPaint.
  3. Use Pencil Tool to make all the pixellings you need. Load "Square Brushes" to paint squares. Which looks like pixels.
  4. Now try to erase it. Is the eraser blurring your image so much you want to chew a rabbit? If you feel as I do, you'll love this one: Change Eraser mode to Pencil. This turns off the anti-alias that Brush Mode performs. You can also change it to Block, which works as a fix-sized square eraser in any zoom level.
  5. For Texts, custom pixelated font is always the better choice because they are designed with pixelation in mind, but a common practice necessary is to change Anti-Alias (the one list option right to font size. It's so very easy to spot) to None. This prevents, again, the evil blurriness. We want our edges sharp.
    • A cool thing about fonts is that all fonts will be pixelated when they became too small. So, if you type the texts small in your desired fancy font, then rasterize it, then transform it to your desired size, you get to create some unique-looking text!
  6. Speaking of Transforming, change the Interpolation to Nearest Neighbor when using it because something something hard edge.
  7. Usually, when you zoom too close to the pixels, Photoshop automatically slaps a grid onto it. This could be distracting and annoying. Turn it off at View/Show/Pixel Grid.
And there you go! You have successfully degraded Photoshop to a more powerful MSPaint! Congratulations!

Art Direction

I've asked many people the simple question of "How to make pixel art". Their answers are similar.

Look at a style you like, and copy that.

My designer artist friend told me that. The Art director at Workinman told me that. A promising pixel art tutorial series said that.
When it comes to making an image interesting and useful, pixel art is no different from the other styles of artworks. And just as in other art styles, there is no silver bullet: many small details go into the look of it. My tip is to use a limited color palette, especially if you are going for a retro style of art. Systems back then don't support that many colors. Use kuler.adobe.com to search for and create your own color palette. Make sure the images look cohesive when put together. Make a mock-up of the gameplay scene first to determine how it'll look, then dissect it into art assets for the programmer to use. Don't use JPG compression.

For further tips and tricks, http://www.pixeljoint.com/forum/forum_posts.asp?TID=11299 is an amazing detailed tutorial addressing many common mistakes and practices. Check it out!

Friday, March 28, 2014

Commarch Report: Fractionauts

Here's the report the team made on Google Doc.

I was away for GDC, hence not being able to contribute to the project. Sorry team!

My thought on the project:
Although git-by-a-bus and the Calloway Coefficient of Fail showed us some terrible results about this project, I feel optimistic about it, because this is a small project built and maintained by a few people that's very easy to reach. Git-by-a-bus or the contributor visualization also doesn't honor some tasks as much, such as the art asset commits from Waterseas.
The tasks in the near future is polishing and shipping the game. Transition effects, bug fixes, Badge implementations, etc. One good functionality to add is randomization of level contents, that'll add infinite replayability instead of the linear and one-time experience we have now. It would also be interesting to add a timer, and value that into the scores, so kids can show off their mad math methods.
It would also be nice to re-skin the game with professional arts, but we would need a good illustrator / designer for that.

Team Proposal: Fractionauts

Blog forked from Jordan Lehman, Eryc Duhart, and KyungHwan Chang.

Team Members, Contacts, and Titles:
Nekocoder           erycduhart010@gmail.com  
Jothle12                 jtl7264@g.rit.edu                    
Kyung                     kxc8603@g.rit.edu                   
PickledChicken   cxl6359@g.rit.edu                    


The Project In Question
Fractionauts, which is an astronaut themed "quiz game" targeted around 4th grade students interested in learning how to perform basic arithmetic with fractions. Hosted by Chris Knepper on Github, it designed for use on the XO, a Python-centered mini-computer.





Our intended contribution has not been set yet, but several options have been brought up: 

  • Packaging-Suggested by Remy himself, packaging and submitting (or patching) the game to XO is a good idea
  • Level Transition Animations
  • Dynamically Generated Questions
  • Interactive Tutorial Level
  • Slowness on XOPC
  • Remedy inability to exit “How to play” screen
  • Give Feedback and Hints to Players


The main contributors to this project so far use the handles Nolski, ChrisKnepper, ExplosiveHippo, Valeatory, Waterseas, and Emmix. Each one has their own copy of the main Github repository, each copy hosted using their main handle name (save for Emmix, which uses the Github name of jrs1498). It is currently assumed that our communications with them will be mainly through e-mail, IRC, and Github.


This post will be edited at a later time with a link to a full community architecture assessment.


Outlook So Far
The Bad: Initial organization of team members seems to be problematic, as communication lines between members are still being set up. In addition, I am unfamiliar with the Python language, so early programming needs may be difficult to fill. The specifics of our contribution also still need to be determined.

The Good: I can tell based on overall attitude and morale that the group is contains several hardworking individuals that are eager to do whatever task they are set to. There also seems to be a good amount of general knowledge within the group regarding the chosen project, despite how "young" the project is.

Monday, February 10, 2014

Lit Review: Ch.3 What is Open Source and How Does it Work?

Who
 - Steve Weber

What
 - Ch.3 What is Open Source and How Does it Work?

Where
 - http://hfoss-fossrit.rhcloud.com/static/books/Weber-SuccessofOpenSource-Chap3.pdf

When
 - published in 2004

The Gist
 - The chapter talks about how open source was invented, what's special about it, and what to do to make it successful.

The Good
 - The comparison and contrast between open source and conventional software development
 - The 8 rules of open source
 - Different ways of organizing an open-source project

The Bad
 - Toooooooooo long. A thick read that could've been about more things.
 - Wish it could be more recent. It'll be interesting if it can look at Github.
 - It's a look at Open Source from an academic and more sociological standpoint. Can't say that's bad, but it's definitely not the full image.

The Questions
 - What notable examples are there where someone starts an open source project, then contributors take it away, starts its own organization, and leads to a successful project?
 - What's the ratio of profitable open source v.s. non-profit open source projects?
 - What are some Court Rulings relating to open-source? How does it impact the community?

The Review
8/10 - "One and a 3/5 thumbs up."

The chapter is a detailed and deep introduction to open source's history and present, albeit quite lengthy and dense. It did a good job explaining how and why open source works, what can make it work, and also goes into detail about licensing, organization, etc. I feel it can still show the information in a clearer way, and I wish it to have a more casual attitude instead of a scholarly paper with charts and data analysis. Overall, a solid 8.

Monday, February 3, 2014

DEAR PEOPLE FROM THE FUTURE: Here's what we figured out so far...

Credit for the name of this blog goes to http://xkcd.com/979/

I'm Changbai Li, a developer currently focusing on web and games. I also design, animate, make music and experiment, all in the name of "making cool shits". Well, "crafting digital experiences" sounds a lot more professional, but the former has a nice ring to it.

This blog is devoted to sharing problems, researches and solutions I faced during the making of these experiences, both in design and development. I put them out, so people from the future won't have to reinvent the Large Hadron Collider again and again.

You're welcome.