Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
ff58616
minor changes
HarutoHiroki Jan 8, 2024
d7b0a27
- Reversed the "any target tiltable" feature, now applying tilt on ta…
HarutoHiroki Mar 28, 2024
5d63071
Create CNAME
HarutoHiroki Mar 28, 2024
9ba6df0
Prep Demo Page
HarutoHiroki Mar 28, 2024
d0a93cb
Merge branch 'main' of https://github.com/HarutoHiroki/PublicGraphTool
HarutoHiroki Mar 28, 2024
2fa0060
bug fix
HarutoHiroki Mar 29, 2024
a702287
small bug fix
HarutoHiroki Apr 2, 2024
d6213bd
new pref bounds courtesy of Listener
HarutoHiroki Apr 5, 2024
63fdbdb
Public release of new features
HarutoHiroki Sep 17, 2024
b082bea
fixing recolor button
HarutoHiroki Oct 7, 2024
c4f3e74
Feat: localization & language selector
potatosalad775 Oct 13, 2024
e2af40c
Merge pull request #2 from potatosalad775/l10n_PR
HarutoHiroki Oct 15, 2024
0c5ec1d
Bringing the public version up to date
HarutoHiroki Jan 5, 2025
13224d3
Fix: broken tilted target selector
potatosalad775 Jan 4, 2025
4b7938d
Fix: Use default language when language selector is disabled
potatosalad775 Jan 6, 2025
3de369f
Merge pull request #4 from potatosalad775/fix/lang-selector
HarutoHiroki Jan 6, 2025
796f875
Merge pull request #3 from potatosalad775/fix/tilted-target-selector
HarutoHiroki Jan 6, 2025
e58adb0
Fix: 'null safety' features
potatosalad775 Jan 6, 2025
62dead1
Small bug fix + various minor edits
HarutoHiroki Jan 6, 2025
709ce4b
Merge pull request #5 from potatosalad775/fix/null-safety
HarutoHiroki Jan 6, 2025
0ff764b
Changing how Translate works: Always use json content if available, o…
HarutoHiroki Jan 6, 2025
f7c73d2
update readme
HarutoHiroki Jan 7, 2025
17e44a7
fix a bug where if df isnt already loaded, prefbounds breaks
HarutoHiroki Jan 9, 2025
348dfe2
fixing the bug fix facepalm
HarutoHiroki Jan 9, 2025
5f03953
bug fixing the bug fix pt.2
HarutoHiroki Jan 10, 2025
9cfa3ba
final bug fix pt.3
HarutoHiroki Jan 10, 2025
8fcf9eb
Added the 90% Inclusion Zone feature
HarutoHiroki Jan 11, 2025
654d1dd
Update README.md
HarutoHiroki Jan 28, 2025
4c347b4
Create CONTRIBUTING.md
HarutoHiroki Jan 28, 2025
8aedc2d
Update README.md
HarutoHiroki Jan 28, 2025
1b6345f
Update CONTRIBUTING.md
HarutoHiroki Jan 28, 2025
8563b6f
Squiglink compatibility
HarutoHiroki Mar 14, 2025
cfca6af
final?
HarutoHiroki Mar 15, 2025
331b10b
fixing rig_description not swapping colors in dark mode
HarutoHiroki Mar 15, 2025
071bf1c
beauty changes, final probably
HarutoHiroki Mar 15, 2025
7aa9d5f
editing migrating.md
HarutoHiroki Mar 15, 2025
8949d54
Making separating targets into a separate folder optional
HarutoHiroki Mar 15, 2025
e25f66d
bringing files up to date
HarutoHiroki Mar 15, 2025
f0d9454
fixing file import issues
HarutoHiroki Mar 15, 2025
e3ab620
analytics must be enabled for certain functions to work, MRS pls fix
HarutoHiroki Mar 15, 2025
df90f24
merging PR from jeromeof into squiglink branch
HarutoHiroki Mar 15, 2025
81023c6
Fixing 90% inclusion feature to now include all variants
HarutoHiroki Mar 15, 2025
24c39f4
forgot to remove this part of code
HarutoHiroki Mar 15, 2025
22453d5
include peq plugin by default
HarutoHiroki Mar 15, 2025
e341b5e
fix target labels
HarutoHiroki Mar 15, 2025
c23bd0e
update devicepeq
HarutoHiroki May 4, 2025
edcd475
remove 0bsd license
HarutoHiroki May 4, 2025
7df38f4
MIT License
HarutoHiroki May 4, 2025
ca82ef3
enable devicePEQ advanced mode
HarutoHiroki May 4, 2025
eb90c03
update devicePEQ and code cleanup
HarutoHiroki Dec 12, 2025
86c15c3
theming adjustments
HarutoHiroki Dec 12, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions CNAME
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
graphtool-demo.harutohiroki.com
6 changes: 6 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# For Contributors
- The code is a mess, I know. I'm working on it. I'm sorry.
- If you want to contribute and help translate the tool, all the source English text is in the `en.json` file. Just copy the file and rename it to your language code (make sure to use ISO 639-1 Language Codes for auto-detection e.g. `fr.json` for French) and translate the text. I'll take care of the rest.
- The translation feature will always prioritize what's in the language files. If a text is missing in the translation file, it will default to the text in the `config.json` file.
- Please don't make any text/value `null`. If you want to not have a text/value, just leave it empty (e.g. `""` or `[]`).
- For targets, each target `"type"` is a key in the language files. The value of the key is the name of the category of targets.
184 changes: 184 additions & 0 deletions Configuring.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,184 @@
# CrinGraph on your own site

This guide explains the steps required to make CrinGraph display your
own FR graphs, for example if by some remarkable circumstance you have
managed to measure IEMs not yet on crinacle.com. If you have any trouble
with setting CrinGraph, or any questions about the tool, just ask me!
Use Github or the email in my profile.

There are two other steps to show people FR graphs that I may not be
able to help with:

* Creating frequency response graphs in the first place. I have never
done this and don't know all the details. You might try reading
[this thread](https://www.head-fi.org/threads/general-iem-measurements-discussions.903455/)
for some information to get you started, and Crin is generally happy
to answer questions about measurement on [his Discord server](https://discord.gg/CtTqcCb).
* Hosting the pages. Believe it or not, I'm not a web developer and I
don't know that much about setting up websites. One method that may
work for your purposes is to use Github Pages, which allows you to
serve the contents of any Github repository as a website. The main
CrinGraph repository includes sample data so it can function on its
own. Once I had the data I just set the source to "master branch" in
the settings under "Github Pages", and Github put the page at
https://mlochbaum.github.io/CrinGraph/graph.html. You can show your
graphs in the same way by forking my repository and making the changes
described here, then changing the "Github Pages" setting like I did.

## Checklist

These are the things you definitely need to change to make sure your
page works and isn't claiming it's crinacle.com.

* Set `DIR` in `config.js` and place your graphs and `phone_book.json`
there.
* Remove or change the watermark.
* Remove the `targets`, replace them with your own, or get permission
from Crinacle to use the ones in the CrinGraph repository.

## Configuring CrinGraph

The main page used to display graphs is [index.html](index.html), which
defines the basic structure of a page and then includes a bunch of
Javascript files that do the real work (at the end of the file).

Ideally all configuration can be done simply by changing
[config.js](config.js). However, there are currently not very many
configuration options. Ask if there's something you want to change but
can't!

Here are the current configuration parameters:

* `DIR` is the location of your FR graphs and the index for them
(see the next section). If you are displaying a cloned repository
using Github Pages, using a directory other than `data/` will make
merging changes from the main CrinGraph repository easier.
* `tsvParse` is a function which takes the text of an FR file and
converts it to the format used internally by CrinGraph. See the next
section.
* `watermark` is a function that is applied once to the graph window on
startup. The argument `svg` is a [d3](https://d3js.org/) selection
and you can use any d3 functionality to draw things in it. This part
must be changed, or you will end up impersonating crinacle.com! To
use no watermark, just delete the whole function body. You can also
delete, move, or change the image and text separately.
* `max_channel_imbalance` controls how sensitive the channel imbalance
detector (that red exclamation mark that can show up in a headphone's
key) is. You probably don't need to change this.
* `targets` lists the available target frequency responses. If you don't
want to display any targets set it to `false`. If you do use targets,
each one should be a file named `... Target.txt` in the `DIR/targets`
directory you specified. The targets which are already there were
provided by Crinacle so make sure you have his permission before using
them.
* `scale_smoothing` (default 1) adjusts the level of smoothing applied
at a given "Smooth:" setting. The setting will always start at 5, but
its value is multiplied by `scale_smoothing` to get the actual level
of smoothing.

The following parameters are used to allow multiple samples per channel
and different channel configurations than L/R. For example,
`config_hp.js` is intended for headphones and shows only the right
channel with five samples per channel.

* `default_channels` is a list of channels in each measurement: it
defaults to `["L","R"]`. It's called "default" because I may add a
mechanism to change it for a single sample from `phone_book.json`,
but no such mechanism exists right now.
* `num_samples`, if set, is the number of samples in each channel.
Samples are always numbered 1 to `num_samples`.

The following parameters are for setting the initial samples to display,
and enabling URL sharing. If enabled, URL sharing updates the page URL
to reflect which samples are on the graph. Copying and opening that URL
will open the page with those samples shown. For these parameters a
headphone or target is identified by its filename.

* `init_phones` is a list of filenames to open by default.
* `share_url` enables URL sharing.
* `page_title` sets the page title display if URL sharing is enabled.

## Storing your FR files

All FR data is stored in its own file in the directory `DIR` you specify
in `config.js`. To use this data, CrinGraph needs two things: an index
which lists the available models, grouped by brand, and the FR curves
themselves.

### FR index: `phone_book.json`

The index is a [JSON](https://en.wikipedia.org/wiki/JSON) file called
[phone_book.json](data/phone_book.json). By default it is located in the
headphone directory `DIR`, but the setting `PHONE_BOOK` allows you to
specify a different filepath. The file's contents are a list of brands,
where each brand is a list of models. A simple example of a brand:

```json
{
"name": "Elysian",
"suffix": "Acoustic Labs",
"phones": [ "Artemis"
, "Eros"
, "Minerva"
, "Terminator" ]
}
```

The only required attributes for a brand are its name ("name") and a
list of headphone models ("phones"). You can also add another part of
the name using "suffix". The suffix is included in the brand name when
it's used alone, but not as part of a model name: here the brand is
"Elysian Acoustic Labs", but the first headphone is the "Elysian Artemis".

Each item in the "phones" array corresponds to a single headphone model.
While an item might just be the model name as shown above, there are
other possibilities as well. Two examples should cover most use cases:

* To use a different display name ("name") and filename ("file"): `{"name":"Carbo Tenore ZH-DX200-CT","file":"Tenore"}`
* To use show multiple variants of a single model: `{"name":"Gemini","file":["Gemini","Gemini Bass"]}`

The full list of options is as follows:

* "name" is the displayed model name.
* "collab" gives the name of a collaborator. If that collaborator is on
the list of brands, the headphone will be categorized under both the
main vendor and the collaborator.
* "file" gives either a single filename or a list. If a list is given,
then "name" is used only to for the headphone's name in the selection
menu. The key will use filenames for display unless one of the following
options is specified.
* "suffix" is a list with the same length as the list of files. The
display name is the model name plus the variant's suffix. So , {"name":"R3","file":["R3","R3 C"],"suffix":["","Custom"]} ]
`{"name":"R3","file":["R3","R3 C"],"suffix":["","Custom"]}` uses files
based on the names `R3` and `R3 C` but shows the names "R3" and
"R3 Custom".
* "prefix" is some string that should appear at the start of each
filename. The display name is then the filename, except that if the
prefix appears at the start of the filename it is replaced with the
display name. So
`{"name":"IER-Z1R","file":["Z1R S2","Z1R S3","Z1R S4","Z1R S5","Z1R S6","Z1R","Z1R Filterless"],"prefix":"Z1R"}`
displays with the names `IER-Z1R S2`, `IER-Z1R S3`, and so on.
You may not need this one because you probably won't measure as many
IER-Z1Rs as Crinacle.

### FR curves

Each frequency response curve (each channel of a headphone, and each
target response) is stored in its own file. For targets this file must
be named using the target name from `config.js` followed by " Target.txt",
for instance "Diffuse Field Target.txt". For headphones the file's name
is obtained from `phone_book.json` as described in the previous section.
When a user selects a headphone, CrinGraph figures out its filename—for
concreteness let's say "New Primacy"—and looks for two files, one for
each channel. Here it would try to read "New Primacy L.txt" and
"New Primacy R.txt". If one channel is not found it will ignore it and
display the headphone with only one channel. If neither one is found it
pops up an alert to say "Headphone not found!" and doesn't display
anything.

The headphone is converted from a text file to a Javascript array
using the setting `tsvParse`. The default setting assumes that the file
is a tab-separated value file, with two header lines which are discarded
followed by 480 measurements (1/48 octave spacing). Each measurement is
a frequency and an SPL value. Of course, you can use any format, as long
as you can write the code to parse it!
Loading