Skip to content

OhmGeek/JDCraw

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

50 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status codebeat badge codecov

JDCraw

Introduction

JDCraw is a wrapper around the popular dcraw executable.

The current system is very much in development, and as such, I wouldn't yet use it in a production system.

Dependencies

The project relies on Maven.

This project relies on the DCRaw executable, built by Dave Coffin. Depending on your operating system, you can install it as follows:

DCRaw Executable

Linux:

Install using the built in package manager.

For Debian/Ubuntu:

sudo apt-get install dcraw

For Fedora:

sudo yum install dcraw

macOS

First, install the brew package manager, if you haven't already.

Then, open Terminal and run the following:

sudo brew install dcraw

Usage

Using JDCraw is very simple. Using a Java File object, simply create an instance of DCRawManager passing the file in:

File fileToEdit = new File('/path/to/file.dng');

DCRawManager manager = new DCRawManager(fileToEdit);

Then, one can use this manager object in several ways.

Operations

DCRaw arguments are expressed in pure English. Let's say I want to flip an image by 90 degrees. Simply create an operation that does that:

RawOperation flipOperation = 
            new FlipImageOperation(FlipAngleEnum.DEGREES90);

Then, add it to the list of operations for DCraw to carry out:

...

manager.addOperation(flipOperation);

Simple!

Tests

There are some tests, but these are not entirely comprehensive. To run the ones present, use Maven:

mvn test

License

Licensed under the MIT License.

DCRaw is licensed under the LGPLv2 license.