How to access the Zen database - for developers.

Official support for: bigtickaudio.com
Post Reply New Topic
RELATED
PRODUCTS

Post

With the latest version of Zen using fxp for presets storage, it is now possible (and very easy) for plugin developers to directly query the Zen database to find and load presets for their synth.

Here is some basic information to get you started:

1. The Zen data folder.
This is where the database and presets are stored. In order to find it, look up the zen.homePath entry in /Documents and Settings/<user>/Application Data/Big Tick/zen/zen.properties. If this entry is not present, the default folder is /Documents and Settings/<user>/Application Data/Big Tick/zen

2. Presets
Presets are referenced by a numeric number: the preset ID. You can find the data for preset ID x in the presets subfolder of the Zen data folder, under the name <x>.fxp.

3. The Zen database
It is a sqlite database located in the Zen folder, and named zendb.s3db
Inside the database you will find all the metadata for the presets. The most useful tables are:

ITEMS: the list of presets.
ATTRIBUTES: the list of tags.
ATTRIBUTES_MAP: the mapping of tags to presets.
SYNTHS: the list of synths.

I suggest you load the database in an SQLITE tool and explore around, or ask me if you want more information. As an example, here is a simple query that returns the first 10 presets for ACE:

Code: Select all

select I.ITEM_ID, I.ITEM_NAME from ITEMS I, SYNTHS S
where S.FXID='acEU' 
and I.SYNTH_ID = S.ATTRIBUTE_ID
order by ITEM_NAME limit 10
ITEM_ID ITEM_NAME
136 Aenima
144 BT 7th scraper (mw+pb+v
145 BT analog pad
4 BT beloved, too (vel)
146 BT broad'n smooth (mw)
147 BT broken shimmer (mw+p"
148 BT butter
149 BT butterfly (mw+vel)
150 BT calm agressor (mw)
151 BT cankered (mw+vel)

another one, to list the tags associated with preset 148 "BT butter":

Code: Select all

select AM.ATTRIBUTE_ID, A.ATTRIBUTE_NAME from ATTRIBUTES_MAP AM, ATTRIBUTES A
where AM.ITEM_ID=148
and AM.ATTRIBUTE_ID=A.ATTRIBUTE_ID
ATTRIBUTE_ID ATTRIBUTE_NAME
8 Pad
23 ACE
35 BigTone
20001 New
20003 Mine (public)

As you can see, this is a Pad by BigTone, for plugin ACE.

Post

This is brilliant work and I look forward to seeing many exploits based upon it. Will you allow us to browse the SQL database with phpMyAdmin (edit) in read only mode, of course(end edit)?

Post

maxmace wrote:This is brilliant work and I look forward to seeing many exploits based upon it. Will you allow us to browse the SQL database with phpMyAdmin (edit) in read only mode, of course(end edit)?
This is the local database that Zen builds on every user computer, not the master database at bigtickaudio.com (for which the answer is, definitely no :))

Post

How do I know 'acEU' translates to the ACE synth, is there a table for this, say I want to query presets where FXID is corresponding to the Feldspar synth?

Post

This is the unique VSt ID of the plugin. The easiest way to find it is to look with a hex editor, at bytes 20-24 in a fxp/fxb saved by the plugin.
You can also use asHost on PC, it shows you the ID when you load the plugin.

Post Reply

Return to “Big Tick”