LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
Search this Thread
Old 03-06-2004, 01:41 PM   #1
sienarot
Member
 
Registered: Mar 2003
Location: Calgary, Alberta, Canada
Distribution: Gentoo 1.4, Debian Woody, Mandrake 8.1
Posts: 43

Rep: Reputation: 15
Python: Bit masking images?


I was wondering if anyone can help me out here...

I have two images. image1.png and image2.png:
- image1.png is basically a regular picture of no significant importance
- image2.png however is an image file of the same size, mode, and format as the first, except that rather than it being a picture, I'm using the image for bit masking. Various pixels are just random decimal numbers denoting series of 1's and 0's which I'd like to mask with the image.

Is there a simple way of using a bitwise AND on the two images? As well, what about OR?

I'm using the Python Imaging Library to do some of these operations, but I'm not sure if any of the merge, compose, blend functions do this and if so, what operations they perform.

Any suggestions?
 
Old 03-06-2004, 02:46 PM   #2
sienarot
Member
 
Registered: Mar 2003
Location: Calgary, Alberta, Canada
Distribution: Gentoo 1.4, Debian Woody, Mandrake 8.1
Posts: 43

Original Poster
Rep: Reputation: 15
Nevermind. I ended up writing up my own routine
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
downloading a bit different images with jigdo dvm Debian 2 06-10-2005 05:16 AM
Bit Torrent and Python 2.4 chalewa4bambu Linux - Software 2 04-25-2005 03:21 PM
bit masking? blackzone Programming 1 08-10-2004 02:41 AM
Graphic Card that Supports displaying 8-bit and 24-bit images simultaneously yrraja Linux - Hardware 2 04-30-2003 06:41 AM
Displaying 8-bit images in 24-bit mode and vice versa yrraja Linux - General 4 04-29-2003 11:54 PM


All times are GMT -5. The time now is 02:20 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration