Skip to content

Commit

Permalink
Initial import
Browse files Browse the repository at this point in the history
  • Loading branch information
commarmi76 committed Apr 13, 2017
1 parent b404608 commit d210b2c
Show file tree
Hide file tree
Showing 58 changed files with 27,798 additions and 339 deletions.
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
build/
sdkconfig.old
.cproject
.project
.settings
5 changes: 5 additions & 0 deletions .gitignore~
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
build/
sdkconfig.old
.cproject
.project

541 changes: 202 additions & 339 deletions LICENSE

Large diffs are not rendered by default.

9 changes: 9 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#
# This is a project Makefile. It is assumed the directory this Makefile resides in is a
# project subdirectory.
#

PROJECT_NAME := proj1

include $(IDF_PATH)/make/project.mk

12 changes: 12 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
ESP-IDF template app
====================

This is a template application to be used with `Espressif IoT Development Framework`_ (ESP-IDF).

Please check ESP-IDF docs for getting started instructions.

Code in this repository is Copyright (C) 2016 Espressif Systems, licensed under the Apache License 2.0 as described in the file LICENSE.

.. _Espressif IoT Development Framework: https://github.com/espressif/esp-idf


8 changes: 8 additions & 0 deletions components/libmp3lame/component.mk
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#
# Component Makefile
#
COMPONENT_ADD_INCLUDEDIRS := include

COMPONENT_SRCDIRS := library

CFLAGS += -Wno-unused-function -DHAVE_EXPAT_CONFIG_H
79 changes: 79 additions & 0 deletions components/libmp3lame/include/VbrTag.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
/*
* Xing VBR tagging for LAME.
*
* Copyright (c) 1999 A.L. Faber
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Library General Public License for more details.
*
* You should have received a copy of the GNU Library General Public
* License along with this library; if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/

#ifndef LAME_VRBTAG_H
#define LAME_VRBTAG_H


/* -----------------------------------------------------------
* A Vbr header may be present in the ancillary
* data field of the first frame of an mp3 bitstream
* The Vbr header (optionally) contains
* frames total number of audio frames in the bitstream
* bytes total number of bytes in the bitstream
* toc table of contents
* toc (table of contents) gives seek points
* for random access
* the ith entry determines the seek point for
* i-percent duration
* seek point in bytes = (toc[i]/256.0) * total_bitstream_bytes
* e.g. half duration seek point = (toc[50]/256.0) * total_bitstream_bytes
*/


#define FRAMES_FLAG 0x0001
#define BYTES_FLAG 0x0002
#define TOC_FLAG 0x0004
#define VBR_SCALE_FLAG 0x0008

#define NUMTOCENTRIES 100

#ifndef lame_internal_flags_defined
#define lame_internal_flags_defined
struct lame_internal_flags;
typedef struct lame_internal_flags lame_internal_flags;
#endif


/*structure to receive extracted header */
/* toc may be NULL*/
typedef struct {
int h_id; /* from MPEG header, 0=MPEG2, 1=MPEG1 */
int samprate; /* determined from MPEG header */
int flags; /* from Vbr header data */
int frames; /* total bit stream frames from Vbr header data */
int bytes; /* total bit stream bytes from Vbr header data */
int vbr_scale; /* encoded vbr scale from Vbr header data */
unsigned char toc[NUMTOCENTRIES]; /* may be NULL if toc not desired */
int headersize; /* size of VBR header, in bytes */
int enc_delay; /* encoder delay */
int enc_padding; /* encoder paddign added at end of stream */
} VBRTAGDATA;

int GetVbrTag(VBRTAGDATA * pTagData, const unsigned char *buf);

int InitVbrTag(lame_global_flags * gfp);
int PutVbrTag(lame_global_flags const *gfp, FILE * fid);
void AddVbrFrame(lame_internal_flags * gfc);
void UpdateMusicCRC(uint16_t * crc, const unsigned char *buffer, int size);

#endif
40 changes: 40 additions & 0 deletions components/libmp3lame/include/bitstream.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
/*
* MP3 bitstream Output interface for LAME
*
* Copyright (c) 1999 Takehiro TOMINAGA
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Library General Public License for more details.
*
* You should have received a copy of the GNU Library General Public
* License along with this library; if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/

#ifndef LAME_BITSTREAM_H
#define LAME_BITSTREAM_H

int getframebits(const lame_internal_flags * gfc);

int format_bitstream(lame_internal_flags * gfc);

void flush_bitstream(lame_internal_flags * gfc);
void add_dummy_byte(lame_internal_flags * gfc, unsigned char val, unsigned int n);

int copy_buffer(lame_internal_flags * gfc, unsigned char *buffer, int buffer_size,
int update_crc);
void init_bit_stream_w(lame_internal_flags * gfc);
void CRC_writeheader(lame_internal_flags const *gfc, char *buffer);
int compute_flushbits(const lame_internal_flags * gfp, int *nbytes);

int get_max_frame_buffer_size_by_constraint(SessionConfig_t const * cfg, int constraint);

#endif
84 changes: 84 additions & 0 deletions components/libmp3lame/include/config.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
/* expat_config.h. Generated from expat_config.h.in by configure. */
/* expat_config.h.in. Generated from configure.ac by autoheader. */

/* 1234 = LIL_ENDIAN, 4321 = BIGENDIAN */
#define BYTEORDER 1234

/* Define to 1 if you have the `bcopy' function. */
#define HAVE_BCOPY 1

/* Define to 1 if you have the <dlfcn.h> header file. */
#define HAVE_DLFCN_H 1

/* Define to 1 if you have the <fcntl.h> header file. */
#define HAVE_FCNTL_H 1

/* Define to 1 if you have the `getpagesize' function. */
#define HAVE_GETPAGESIZE 1

/* Define to 1 if you have the <inttypes.h> header file. */
#define HAVE_INTTYPES_H 1

/* Define to 1 if you have the `memmove' function. */
#define HAVE_MEMMOVE 1

/* Define to 1 if you have the <memory.h> header file. */
#define HAVE_MEMORY_H 1

/* Define to 1 if you have a working `mmap' system call. */
#define HAVE_MMAP 1

#define HAVE_ERRNO_H 1

/* Define to 1 if you have the <stdint.h> header file. */
#define HAVE_STDINT_H 1

/* Define to 1 if you have the <stdlib.h> header file. */
#define HAVE_STDLIB_H 1

/* Define to 1 if you have the <strings.h> header file. */
#define HAVE_STRINGS_H 1

/* Define to 1 if you have the <string.h> header file. */
#define HAVE_STRING_H 1

/* Define to 1 if you have the <sys/param.h> header file. */
#define HAVE_SYS_PARAM_H 1

/* Define to 1 if you have the <sys/stat.h> header file. */
#define HAVE_SYS_STAT_H 1

/* Define to 1 if you have the <sys/types.h> header file. */
#define HAVE_SYS_TYPES_H 1

/* Define to 1 if you have the <unistd.h> header file. */
#define HAVE_UNISTD_H 1

/* Define to the sub-directory in which libtool stores uninstalled libraries.
*/
#define LT_OBJDIR ".libs/"


/* Define to 1 if you have the ANSI C header files. */
#define STDC_HEADERS 1

/* whether byteorder is bigendian */
/* #undef WORDS_BIGENDIAN */



/* Define to __FUNCTION__ or "" if `__func__' does not conform to ANSI C. */
/* #undef __func__ */

/* Define to empty if `const' does not conform to ANSI C. */
/* #undef const */

/* Define to `long int' if <sys/types.h> does not define. */
/* #undef off_t */

/* Define to `unsigned int' if <sys/types.h> does not define. */
/* #undef size_t */

#undef HAVE_NASM
#undef HAVE_MPGLIB
#undef HAVE_XMMINTRIN_H
Loading

0 comments on commit d210b2c

Please sign in to comment.