epuBear
Lightweight, easily customizable cross-platform EPUB SDK for EPUB readers development
About epuBear SDK
Cross-platform close Core of epuBear SDK provides the following basic functionality:
Features
- Full compatibility with EPUB2 and partially with EPUB3
- Open, unpack and parse EPUB document
- Read EPUB document from file and from memory (byte array)
- Get EPUB document info
- Render pages to bitmaps
- Global language support
Functions
- Go to Page
- Go to Chapter
- Open Link
- Change Font Size
- Switch to DoublePage Mode
- Switch to Night Mode
- Bookmarks
- Text Search
- Select Text
- Change Text Color
- Change Background Color
- Audio and Video Support
- Set Custom Fonts
- Open Image in a Separate Window
- Vertical and Right-to-Left Writing
This set of features will be available to you right after the purchase. Even though this may seem like all boxes are ticked at first, please feel free to let us know if you consider adding extra features, like DRM that could be a good fit for your product. As our primary activity is software development, we'd like to provide you with native customization and maintenance.
How to use
This EPUB SDK is a C++ solution and we prepared native wrappers in Java (Android), Swift (iOS) and C# (Xamarin) for our EPUB toolkit to be compatible with your project. The code of the wrappers acts as a proxy between the native code and the core.
/* Initialization */
import com.epubear.EpubearFramework;
public class EpubearView extends View implements EpubearFramework.EventListener {
private EpubearFramework epubear;
private Map bitmaps;
public EpubearView(Context context) {
....
// create instance
epubear = new EpubearFramework(context, dataDir);
epubear.setEventListener(this);
....
}
@Override
public void onSizeChanged(int w, int h, int oldw, int oldh) {
....
// init framework with target width/height
epubear.updateBitmapSize(w, h);
....
}
@Override
public void doInitDisplay() {
....
// create bitmaps
// register them in framework
for (Map.Entry entry : bitmaps.entrySet())
epubear.registerBitmap(entry.getKey(), bitmap.getValue());
....
}
}
/* Navigation */
// open epub
epubear.openFile(path);
// go to next page
epubear.openNextPage();
// go to previous page
epubear.openPreviousPage();
// get Table of Contents
Map tocList = epubear.tableOfContents();
// open chapter from table of contents
epubear.openChapter(caption);
// font increase
epubear.increaseFont();
// font increase
epubear.decreaseFont();
// Framework initialization and book opening, if book cannot be opened returns nil
// BookViewController.swift
override func viewWillAppear(animated: Bool) {
...
frameworkInstance = EPUBearFramework(bookPath: self.bookPath, withCachePath: self.cachePath)
...
}
override func viewDidLayoutSubviews() {
...
let scale = UIScreen.mainScreen().scale;
let scaledSize = CGSize(width: view.bounds.size.width * scale, height: view.bounds.size.height * scale)
frameworkInstance.resizeBitmapsIfNeeded(scaledSize)
...
}
// Bitmaps getters
frameworkInstance.centerImage();
frameworkInstance.leftImage();
frameworkInstance.rightImage();
// Navigation through book
frameworkInstance.openNextPage();
frameworkInstance.openPreviousPage();
frameworkInstance.openPage(page);
// Navigation through chapters
frameworkInstance.openChapterAtIndex(index);
// Change font size
frameworkInstance.increaseFont();
frameworkInstance.decreaseFont();
// BookViewController.cs
private EPUBearFramework _framework;
public override void ViewDidLoad()
{
base.ViewDidLoad();
var bookPath = (Element as BookPage).BookPath;
var cachePath = (Element as BookPage).CachePath;
_framework = new EPUBearFramework(bookPath, cachePath);
_framework.WeakDelegate = this; // to handle framework callbacks
}
public override void ViewDidLayoutSubviews()
{
...
var viewSize = View.Bounds.Size;
var scale = UIScreen.MainScreen.Scale;
var scaledSize = new CGSize(viewSize.Width * scale, viewSize.Height * scale);
_framework.ResizeBitmapsIfNeeded(scaledSize);
...
}
// Book Navigation
_framework.OpenChapterAtIndex(chapterIndex);
_framework.OpenPage(pageNumber);
_framework.OpenPreviousPage();
_framework.OpenNextPage();
// Change font size
_framework.IncreaseFont();
_framework.DecreaseFont();
// Way to access rendered pages as CGImage objects
var pages = new CGImage[3];
pages[0] = _framework.LeftImage;
pages[1] = _framework.CenterImage;
pages[2] = _framework.RightImage;
// Way to check first && last pages
_framework.CanScrollToLeft;
_framework.CanScrollToRight;
// Way to change night\normal mode
_framework.SetAppearanceMode(EPUBAppearanceMode);
// Framework delegate methods
IEPUBearFrameworkDelegate.ContentUpdated();
IEPUBearFrameworkDelegate.PageCountChanged(pageCount);
Coming soon
Use the links below to download developer documentation:
epuBear Demo Reader
Our epuBear Reader acts as a standalone reader for books in EPUB format with no ads and no limitations in functionality. It is based on epuBear SDK developed by Scand. Besides, the apps show the benchmark report of epuBear performance.
epuBear Demo Reader Features:
- Compatibility with EPUB 2 format
- Navigation through pages, chapters, bookmarks, and links
- Night mode
- Text search
- Audio and Video support
Pricing
- 1 Binary Licence
- 1 Application
- 1 Mobile Platform
- 1 Year of support
Custom Solution
There is also a possibility to compile a custom e-publishing solution from the already predefined components like Epubear SDK, Epub Cloud, Epub Viewer, Text Reader, Page Curl, Epub Media, Crypto Gateway, or you can request a full functional DRM system.
Related products
- EpubCloud EpubCloud hosts, stores, and shares EPUB files for their further reading from various devices addin to synchronize contacts, calendars, and tasks View product
- Crypto Gateway Crypto Gateway is a service that allows encrypting and delivering content to display on any device in a secure way. View product
- CurlEffect for Xamarin An out-of-the-box library that creates a page curl effect for Xamarin apps View product
-
More products
developed by SCAND