Showing posts with label effect. Show all posts
Showing posts with label effect. Show all posts

Monday, February 6, 2017

Gimp Tutorial Awesome Bokeh Effect in Gimp

Gimp Tutorial Awesome Bokeh Effect in Gimp


It was fun to to follow Abduzeedo tutorial for making bokeh digital effect in Photoshop (im using photoshop and gimp) and i really excited when i managed to do similiar effect in Gimp. So i decided to make a Gimp tut for this one..its been over a months since my last tutorial and i think after this ill make more Gimp tuts..Click More Inside The Post to read the tutorial.


Gimp Digital Bokeh


P/s: This tutorial has been converted from the original Photoshop tutorial into Gimp. The original Photoshop tutorial can be found HERE in Abduzeedo site.


Before you try this tutorial,please download my Eclipse brush where i made it by myself. You can download the brush by click HERE. After download it, paste the brush to Gimp folder. And im using Gimp 2.6 for this one.

P/S : Click the image for larger view.


Create new document. Ill used 1600 x 1200. Fill the background with blackcolour .



Then create new layer.I renamed it as dark violet.



Choose a dark purple. Im using #b10993.



Select gradient tool, Radial for the shape and low the opacity to 50. Click the image for larger view.




Now create a new layer and i renamed it as eclipse.



Select the brush tool. and Ill using my Eclipse brush. Use white color for the brush.Then Select brush dynamic options and for the values use the image below.



Now well paint some ellipses at the eclipse layer.



Go to Filters>Blur>Gaussian Blur. For this first layer use 40 pixels for the Horizontal and 40 pixels for the Vertical.





Create another layer ( I named it eclipse 2 ) and start painting again.



Go to Filters>Blur>Gaussian Blur. For this second layer use 10 pixels for the Horizontal and 10 pixels for the Vertical




Create another layer and repeat the previous step, this time however ill Apply the Gaussian Blur to this layer as well, but use only 1 pixel for the Radius.



And then create a new layer and i named it as Clouds.Fill it with white. Go to Render>Clouds>Different Clouds.and apply to the layer. I use 4 for the Detail, Randomize and Tileable.After that changes the layer mod to Overlay.





Create another layer and named it gradient.



Using the gardient tools select Full Saturation Spectrum Gradient , 100 for the opacity and Linear for the shape.



Apply the gradient to the layer. Change the layer mod to Overlay.Ull see a nice effect there.



Go to layer eclipse 3 and change the layer mod to Grain merge.



Last,go to layer 2 and change the layer mod to Hard Light



Finish!



Result



Below is my result using Photoshop..You will noticed that Gimp is a great free editing software ever because it can achieve almost the same as Photoshop result.




hope u like it..i take no credit of this awesome effect.credit all to Fabio Sasso for the inspiring idea.


I also included the Xcf file.
Click here to download the Xcf file used for this tutorial


UPDATED: 2 FEBRUARY 2009

I HAVE MADE NEW BOKEH .GBR BRUSH SO FEEL FREE TO DOWNLOAD IT HERE. THIS IS MY NEW RESULT USING THE BRUSH. MADE IN GIMP 2.6.4.


BOKEH RESULT2

Available link for download

Read more »

Thursday, January 26, 2017

Great performance effect of fixing broken group commit

Great performance effect of fixing broken group commit


Yesterday InnoDB Plugin 1.0.4 was released by Innobase. This version contains one of the most important performance fixes - "Fix for broken group commit". After MySQL5.0, InnoDB breaks group commit when using with binary log (or with other transactional storage engines), even though setting innodb_support_xa=0. This was really serious because fsync() (called at transaction commit when setting innodb_flush_log_at_trx_commit=1) is very expensive. The initial bug report about this was submitted by Peter four years ago. Last year David Lutz submitted a bug report with his prototype patch. It is great news that this bug fix has been finally implemented in the official InnoDB release.
I did a simple benchmarking by mysqlslap. mysqlslap has functionality to run concurrent inserts from multiple connections. The result is as follows.
mysqlslap --concurrency=1,5,10,20,30,50 --iterations=1 --engine=innodb 
--auto-generate-sql --auto-generate-sql-load-type=write
--number-of-queries=100000


H/W is Sun Fire X4450, Intel Xeon X5560 Nehalem 2.80GHz * 16cores, 12GB RAM, SAS HDD with write cache. my.cnf configuration is as follows. log-bin is enabled.

[mysqld]
basedir=/usr/mysql5137
datadir=/data/mysql5137/data
ignore_builtin_innodb
plugin-load=innodb=ha_innodb.so;innodb_trx=ha_innodb.so;
innodb_locks=ha_innodb.so;innodb_lock_waits=ha_innodb.so;
innodb_cmp=ha_innodb.so;innodb_cmp_reset=ha_innodb.so;
innodb_cmpmem=ha_innodb.so;innodb_cmpmem_reset=ha_innodb.so
innodb_log_files_in_group=2
innodb_buffer_pool_size=2G
innodb_flush_method=O_DIRECT
innodb_log_file_size=512M
innodb_data_file_path=ibdata1:500M:autoextend
innodb_file_per_table
log-bin
table_cache=8192

Apparently InnoDB Plugin 1.0.4 outperforms normal InnoDB (6.1 times faster on 30 connections, innodb_support_xa=1). Normal InnoDB doesnt scale with connections but InnoDB Plugin 1.0.4 does. What is the difference? Normal InnoDB does the following at transaction commit.
pthread_mutex_lock(&prepare_commit_mutex)
writing into InnoDB logfile for prepare, then fsync
(skipped if innodb_support_xa=0)
writing into binlog
writing into InnoDB logfile for commit, then fsync
pthread_mutex_unlock(&prepare_commit_mutex)

Under the critical section protected by prepare_commit_mutex, only one thread can do operation. So when 100 threads do commit at the same time, fsync() is called 100 times for prepare, 100 times for commit (200 in total). Group commit is totally broken. As you see the above graph, innodb_support_xa=0 is effective (though it still breaks group commit), but in general innodb_support_xa=0 is not recommended because it will break consistency between binlog and InnoDB in case of a crash.
In InnoDB Plugin 1.0.4, the behavior has changed as follows.
writing into InnoDB logfile for prepare, then fsync
(skipped if innodb_support_xa=0)
pthread_mutex_lock(&prepare_commit_mutex)
writing into binlog
writing into InnoDB logfile for commit
pthread_mutex_unlock(&prepare_commit_mutex)
fsync to the InnoDB logfile

fsync, the most expensive operation, is called outside the critical section, so group commit is possible and concurrency is much more improved. The following graph shows how much Innodb_data_fsyncs was increased after executing mysqlslap(committing 100,000 transactions).


In 5.1.37+Builtin(support_xa=1), 2 fsyncs happens per transaction, regardless of # of concurrent connections. In 5.1.37+Builtin(support_xa=0), 1 fsync happens per transaction, regardless of # of concurrent connections. These mean group commit is broken. In both cases about 10,000 fsyncs were executed per second, which seems upper limit for regular HDD with BBU. On the other hand, InnoDB Plugin 1.0.4 greatly reduces the number of fsyncs(i.e. 200251 to 26092 on 30 connections(innodb_support_xa=1): 87% decreased). This shows group commit works well.

Write ordering between binlog and InnoDB logfile is still guaranteed. Write ordering for InnoDB prepare is not same as the ordering of binlog, but this is fine. Prepared entries are used only for recovery and not visible to applications. When doing crash recovery, mysqld reads binlog at first(picking up xids), then checking prepared but not committed entries(xids) in InnoDB logfile, then applying these entries in the order of binlog xids. So in the end write ordering is guaranteed.
Note that if you set sync_binlog=1, it is still very slow because writing into binlog is protected by mutex (prepare_commit_mutex and LOCK_log).
This is my understanding. InnoDB Plugin 1.0.4 also has other awesome features (i.e. multiple i/o threads) so its worth trying.

Available link for download

Read more »