~ubuntu-branches/ubuntu/utopic/cdrdao/utopic

« back to all changes in this revision

Viewing changes to trackdb/lec.h

  • Committer: Bazaar Package Importer
  • Author(s): Andrew Suffield
  • Date: 2004-06-24 22:33:16 UTC
  • Revision ID: james.westby@ubuntu.com-20040624223316-534onzugaeeyq61j
Tags: upstream-1.1.9
ImportĀ upstreamĀ versionĀ 1.1.9

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*  cdrdao - write audio CD-Rs in disc-at-once mode
 
2
 *
 
3
 *  Copyright (C) 1998-2002 Andreas Mueller <mueller@daneb.ping.de>
 
4
 *
 
5
 *  This program is free software; you can redistribute it and/or modify
 
6
 *  it under the terms of the GNU General Public License as published by
 
7
 *  the Free Software Foundation; either version 2 of the License, or
 
8
 *  (at your option) any later version.
 
9
 *
 
10
 *  This program is distributed in the hope that it will be useful,
 
11
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 
12
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
13
 *  GNU General Public License for more details.
 
14
 *
 
15
 *  You should have received a copy of the GNU General Public License
 
16
 *  along with this program; if not, write to the Free Software
 
17
 *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 
18
 */
 
19
 
 
20
#ifndef __LEC_H__
 
21
#define __LEC_H__
 
22
 
 
23
#include <sys/types.h>
 
24
 
 
25
 
 
26
/* Encodes a MODE 0 sector.
 
27
 * 'adr' is the current physical sector address
 
28
 * 'sector' must be 2352 byte wide
 
29
 */
 
30
void lec_encode_mode0_sector(u_int32_t adr, u_int8_t *sector);
 
31
 
 
32
/* Encodes a MODE 1 sector.
 
33
 * 'adr' is the current physical sector address
 
34
 * 'sector' must be 2352 byte wide containing 2048 bytes user data at
 
35
 * offset 16
 
36
 */
 
37
void lec_encode_mode1_sector(u_int32_t adr, u_int8_t *sector);
 
38
 
 
39
/* Encodes a MODE 2 sector.
 
40
 * 'adr' is the current physical sector address
 
41
 * 'sector' must be 2352 byte wide containing 2336 bytes user data at
 
42
 * offset 16
 
43
 */
 
44
void lec_encode_mode2_sector(u_int32_t adr, u_int8_t *sector);
 
45
 
 
46
/* Encodes a XA form 1 sector.
 
47
 * 'adr' is the current physical sector address
 
48
 * 'sector' must be 2352 byte wide containing 2048+8 bytes user data at
 
49
 * offset 16
 
50
 */
 
51
void lec_encode_mode2_form1_sector(u_int32_t adr, u_int8_t *sector);
 
52
 
 
53
/* Encodes a XA form 2 sector.
 
54
 * 'adr' is the current physical sector address
 
55
 * 'sector' must be 2352 byte wide containing 2324+8 bytes user data at
 
56
 * offset 16
 
57
 */
 
58
void lec_encode_mode2_form2_sector(u_int32_t adr, u_int8_t *sector);
 
59
 
 
60
/* Scrambles and byte swaps an encoded sector.
 
61
 * 'sector' must be 2352 byte wide.
 
62
 */
 
63
void lec_scramble(u_int8_t *sector);
 
64
 
 
65
#endif