Download the free trial version
Basic4android Video
Features
Tutorials and manuals
Showcase
Screenshots

Go Back   Android Development Forum - Basic4android > Basic4ppc (Windows Mobile) > Code Samples & Tips > Additional Libraries
Documentation Wiki Register Members List B4P Search Today's Posts Mark Forums Read

Additional Libraries Users contributed libraries.
This sub-forum is only available to licensed users.

ImageLibEx library

Reply
 
LinkBack Thread Tools Display Modes
  #141 (permalink)  
Old 02-05-2010, 09:29 AM
agraham's Avatar
Basic4ppc Expert
 
Join Date: Jul 2007
Location: Cheshire, UK
Posts: 5,953
Awards Showcase
Innovator medal Beta Tester Forum Contributer 
Total Awards: 3
Default

Coredll.dll is the main device native code library. There is not a desktop version of it. The advanced drawing functions are implemented entirely differently on the desktop to the device, that is why there are two ImageLibEx libraries. The device needs to call native code for some things that are available in the .NET Framework on the desktsop. To implement gradient fill you will also need two different libraries or possibly one with conditional statements to do the right thing at runtime.
__________________
Sorry, but I don't answer questions by PM or email.
Please post your queries in the forum.
Reply With Quote
  #142 (permalink)  
Old 02-05-2010, 09:47 AM
derez's Avatar
Basic4ppc Expert
 
Join Date: May 2007
Posts: 918
Awards Showcase
Beta Tester Competition Winner 
Total Awards: 2
Default

Thank you.
__________________
David Erez
Ramat Hasharon, Israel
Reply With Quote
  #143 (permalink)  
Old 02-06-2010, 11:52 AM
agraham's Avatar
Basic4ppc Expert
 
Join Date: Jul 2007
Location: Cheshire, UK
Posts: 5,953
Awards Showcase
Innovator medal Beta Tester Forum Contributer 
Total Awards: 3
Default

Version 2.1 now posted includes support for individual pixel alpha values so you can now blend images with alpha values, such as PNGs, and get proper transparency. See the "Alpha blending overview" in the help.
__________________
Sorry, but I don't answer questions by PM or email.
Please post your queries in the forum.

Last edited by agraham : 02-07-2010 at 07:02 PM.
Reply With Quote
  #144 (permalink)  
Old 02-06-2010, 12:00 PM
Basic4ppc Expert
 
Join Date: May 2008
Location: Italy
Posts: 541
Awards Showcase
Beta Tester 
Total Awards: 1
Default

Thank you!

Where do you find the time (and the inspiration)? Any secrets you may share with us "normal human beings" to benefit from?

Quote:
Originally Posted by agraham View Post
Version 2.1 now posted includes support for individual pixel alpha values so you can now blend images with alpha values, such as PNGs, and get proper transparency. See the "Alpha blending overview" in the gelp.
__________________
rgds,
moster67
Reply With Quote
  #145 (permalink)  
Old 02-06-2010, 12:11 PM
agraham's Avatar
Basic4ppc Expert
 
Join Date: Jul 2007
Location: Cheshire, UK
Posts: 5,953
Awards Showcase
Innovator medal Beta Tester Forum Contributer 
Total Awards: 3
Default

Quote:
Originally Posted by moster67 View Post
Any secrets you may share with us "normal human beings" to benefit from?
Retire early and keep body and mind active (I manage the mind bit anyway!)
__________________
Sorry, but I don't answer questions by PM or email.
Please post your queries in the forum.
Reply With Quote
  #146 (permalink)  
Old 02-07-2010, 06:52 PM
Merlot2309's Avatar
Basic4ppc Veteran
 
Join Date: Feb 2009
Location: Spain
Posts: 288
Default

Andrew,

Just used this lib for the first time and I can't tell you enough how happy I am with the pieces of art that you create.

A huge THANK YOU!!

Regards,
Helen.
__________________
IPhone 4 - HTC Legend - HTC Touch Diamond 2
Android 2.2 Tablet 10.2" (Chinese Superpad 3)
Reply With Quote
  #147 (permalink)  
Old 02-09-2010, 02:56 AM
Junior Member
 
Join Date: Sep 2009
Posts: 47
Default

Thank you for the latest library which helped me to solve the png alphabend issue. Hopefully you can give me some pointer how I can do the below:

I've 2 images to be blend together. The 1st one is a normal jpg (base image), and the 2nd one is a smaller png with transparent image.

I can blend them together using the AlphaPixelBlend. My question: is there a better way I can resize & crop part of the png before merging it to the jpg?


My current code seems to be a bit lengthy:
1. Resize the jpg to smaller (losing info) using drawerEx.DrawImage
2. AlphaPixelBlend the 2 images
3. resize it for display

Last edited by chanppc : 02-09-2010 at 02:59 AM.
Reply With Quote
  #148 (permalink)  
Old 02-09-2010, 09:44 AM
agraham's Avatar
Basic4ppc Expert
 
Join Date: Jul 2007
Location: Cheshire, UK
Posts: 5,953
Awards Showcase
Innovator medal Beta Tester Forum Contributer 
Total Awards: 3
Default

The alpha bitmap has a width of mainimage.width/3 +1 and a height of mainimage.height. Using DrawImage you should be able to crop the main image starting at an x that is a multiple of three and crop the alpha bitmap to match starting at x/3 with a length of newmainwidth/3 + 1. As the vertical resolutions are the same use the same y start and height for both.

I don't think resizing will work without giving you some edge effects but you could try and see what it looks like.
__________________
Sorry, but I don't answer questions by PM or email.
Please post your queries in the forum.
Reply With Quote
  #149 (permalink)  
Old 02-10-2010, 01:30 PM
Junior Member
 
Join Date: Sep 2009
Posts: 47
Default

Thanks again Agraham, I manage to get it work!
Reply With Quote
  #150 (permalink)  
Old 02-19-2010, 03:36 AM
Newbie
 
Join Date: Jun 2009
Posts: 8
Awards Showcase
Beta Tester 
Total Awards: 1
Default

I thought a cirlce will be located at the very center, but result is different. it's moved to right-bottom a little bit.
What is wrong on my script?

Advise me, please...

'cvs: BitmapEx, drw: DrawerEx, pen: PenEx
frmMain.Show
cvs.New2(frmMain.Width, frmMain.Height)
xCtr = cvs.Width/2
yCtr = cvs.Height/2
pen.New1(cBlue)
drw.New2(cvs.Value)

drw.DrawCircle(pen.Value, xCtr, yCtr, 133)

frmMain.DrawImage(cvs.Value,0,0)
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Door library (Beta) - Special library Erel Official Updates 60 01-13-2011 12:23 PM
Merging Outlook library and Phone library Erel Official Updates 11 09-15-2010 10:22 AM
PhoneticAlgorithms Library (ex-StringComparison Library) moster67 Additional Libraries 10 11-11-2008 08:46 PM
ImageLibEx? agraham Basic4ppc Wishlist 2 11-05-2007 02:15 PM
ImageLibeX Error XerVision Questions (Windows Mobile) 8 08-27-2007 07:14 PM


All times are GMT. The time now is 02:17 AM.


Powered by vBulletin® Version 3.6.12
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0