| 1 |
/************************************************************************* |
| 2 |
* Copyright (c) 2011 AT&T Intellectual Property |
| 3 |
* All rights reserved. This program and the accompanying materials |
| 4 |
* are made available under the terms of the Eclipse Public License v1.0 |
| 5 |
* which accompanies this distribution, and is available at |
| 6 |
* https://www.eclipse.org/legal/epl-v10.html |
| 7 |
* |
| 8 |
* Contributors: Details at https://graphviz.org |
| 9 |
*************************************************************************/ |
| 10 |
|
| 11 |
#pragma once |
| 12 |
|
| 13 |
#include <stdbool.h> |
| 14 |
#include <topfish/hierarchy.h> |
| 15 |
|
| 16 |
typedef struct { |
| 17 |
int num_foci; |
| 18 |
int *foci_nodes; /* Nodes in real graph */ |
| 19 |
double *x_foci; /* Universal coordinates */ |
| 20 |
double *y_foci; |
| 21 |
} focus_t; |
| 22 |
|
| 23 |
typedef struct { |
| 24 |
// all must be set |
| 25 |
double width; ///< viewport width |
| 26 |
double height; ///< viewport height |
| 27 |
double distortion; /* default of 1.0 */ |
| 28 |
} reposition_t; |
| 29 |
|
| 30 |
void positionAllItems(Hierarchy * hp, focus_t * fs, |
| 31 |
reposition_t * parms); |
| 32 |
Hierarchy *makeHier(int nnodes, int nedges, v_data *, double *, double *, |
| 33 |
bool dist2_limit); |
| 34 |
|
| 35 |
focus_t *initFocus(int ncnt); |