Sunday, January 23, 2011

Imagemagick. GMP. Mbrola. Speex.

Freeimage finally got to me: doesn't handle transparency. Then, I remembered a friend of mine talking about ImageMagick. I was amazed by the rich API - more than 500 functions for MagickWand interface than enables you do almost anything when it comes to image processing. I've written a wrapper for it: http://www.radgs.com/docs/help/standard.graph.imagemagick.html.
Easy and clean interface, with lots of supported formats, it seems to be the best solution for Gyro image processing. It can also output text on images, using custom fonts.

Concept doesn't handle fractions, and sometimes you need fractional computations. After a little research, I discovered GMP, a fast library that can handle big integers (and I mean VERY BIG), rational numbers, big floating points numbers and has even a random number generator. It can do prime checks, greatest common divisor and more.

Here is the API documentation: http://www.radgs.com/docs/help/standard.math.gmp.html

For some time, I wanted a TTS(text to speech) engine API in Concept. It was a hard decision, but I went for a closed-source project: Mbrola.
The main reasons were:
  • Nice and clean API
  • Support for many languages
  • Fast
  • Cross platform
So what if is not Open Source?!
I wanted to write a plug-in for GyroGears to read the errors. Then, an application could tell you "that's wrong, you retard".
The true reason for this is accessibility for people that can't see. I have a friend in that situation, and told me that GTK is unavailable for him because it doesn't work well with screen reader software. Problem solved now with MBROLA.

Concept Client has an audio stream interface that can handle speex compressed streams. In conjunction with mbrola, now an audio stream can be compressed by the server, using the low-level interface http://www.radgs.com/docs/help/standard.arch.speex.html or the high-level, convenient interfaces http://www.radgs.com/docs/help/SpeexDecoder.html and http://www.radgs.com/docs/help/SpeexEncoder.html. This enables you to compress the audio data on the server, in real time using speex (a free codec for free speech).

On Gyro, I've debugged, as usual. Also, the alerts are now prettier and tested in real-life application.
Notice the yellow zone - the alerts.

Some minor bugs fixed in concept core and standard.lib.str that caused some problems with string constants containing the zero character.

This week I will focus on the GyrGears chart library (gdcharts). There are some problems with charts that don't feet in the designated area and causes a crash. I want to try to fix gdcharts or replace it with swfdec + open flash charts (looking very cool).

Wednesday, January 5, 2011

Security even for non crypted for Concept 2.0

I've added a few features in Concept 2.0:
  • Chunked files and cookies: This allows the asynchronous transfer of files between the server and client, files of virtually unlimited size
  • Optimized transfer for non-chunked files (the client now receives the file buffer only if the user accepted it)
  • Security warnings for the Concept Client when an application tries to execute a potentially dangerous command
  • Optimized concepts:// protocol (less CPU cycles per message)
  • Secure log-in for uncrypted sessions. For now, 3 methods of authentication are available: MD5, SHA1, and PLAIN. Old clients are using the PLAIN method by default, but for new applications SHA1 is recommended. The password is returned as (for SHA1): SHA1(challenge + SHA1(password)). Challenge is a 64 character random generated buffer (characters with values from 0 to 0xFF).
  • In GyroGears: SQLiteNoLock driver was added in order to avoid transactions when using SQLite (SQLite locks the entire database instead of just only one row).
  • A major change in the Gyro generated ORM: for file and multimedia data type, if object is stored on disk, instead of the object buffer, it returns the File handle.
  • Minor bug-fixes in the log system of Concept Application Server that caused "unknown" ip has been disconnected.