PetteriAimonen / focus-stack

Fast and easy focus stacking
MIT License
249 stars 37 forks source link

Build process on MacOS #5

Closed alsmithson closed 4 years ago

alsmithson commented 4 years ago

Could you provide guidance in the readme on how to build this on MacOS? I am not a computer geek, but I would like to use this program in my photography.

PetteriAimonen commented 4 years ago

Yeah, I could. But it may be a while before I have time to test it out.

Here is a guess, but I haven't tested this yet:

  1. Install homebrew: /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"

  2. Install OpenCV and git: brew install git opencv

  3. Clone the focus-stack repository: git clone https://github.com/PetteriAimonen/focus-stack.git and go there: cd focus-stack

  4. Build: make and make install

alsmithson commented 4 years ago

Thanks. It took 6 hours to get OpenCV built (thanks to its seemingly thousands of highly specific dependencies). Your make went well, but make install did not like the -D switch. Deleted the -D and the install seemed to work. I can launch your executable fine, but I'm too exhausted to actually try making a focus stack right now.

PetteriAimonen commented 4 years ago

Thanks for trying it out! I'll keep this open until I've added the build instructions to docs.

I guess I should provide binary package for Mac OS X also, to avoid the long build.

dannephoto commented 4 years ago

I'd love to test out a mac binary.

PetteriAimonen commented 4 years ago

@dannephoto @alsmithson There is now a Mac OS package available here for testing: https://jpa.kapsi.fi/jenkins/job/focus-stack/job/focus-stack%20MacOSX/lastSuccessfulBuild/artifact/distrib/focus-stack_MacOSX.zip

You'll need to allow it separately from system settings as it is unsigned.

dannephoto commented 4 years ago

Thanks a lot! Testing to download but seems interrupted(fails) everytime. Maybe Jenkins server. I´ll try harder and get back if I still can´t download it. EDIT: Really slow. Says 20 minutes but fails after 5. Alternate download area possible?

PetteriAimonen commented 4 years ago

Hmm, funny, it is proxied to behind my home connection but for me it still downloads in less than a minute.

I uploaded a copy here, perhaps it works better as this directory is on a faster connection: https://jpa.kapsi.fi/stuff/other/focus-stack_MacOSX.zip

dannephoto commented 4 years ago

Still slooow :). what about sprend.com ? Anyway. Gotta run. Will check in here later tonight again.

PetteriAimonen commented 4 years ago

@dannephoto I had a few friends try, works well for them. But for what it's worth, here's it on github: https://github.com/PetteriAimonen/focus-stack/releases/download/0.9/focus-stack_MacOSX.zip

I won't be distributing binaries over random file sharing services.

dannephoto commented 4 years ago

Thanks. Github did the trick. Tested working. Align algoritm is so fast. Outputs jpg, how about tiff high resolution alternative? On a sidenote. Since aligning works so effectively. Is it possible to tweak the app to do enfusing/averaging to reduce noise in output? Average let´s say some 50 images into 1? Thanks for help.

PetteriAimonen commented 4 years ago

You can output any format supported by opencv with e.g. --output=img.tiff.

Averaging etc. other features might be added in future, but for now, the application is about focus stacking only. Focus stacking in itself tends to select the noisiest images of the stack, as they have the most contrast.