FM

//lib64/python3.6 UP

"""Simple class to read IFF chunks.

An IFF chunk (used in formats such as AIFF, TIFF, RMFF (RealMedia File
Format)) has the following structure:

+----------------+
| ID (4 bytes)   |
+----------------+
| size (4 bytes) |
+----------------+
| data           |
| ...            |
+----------------+

The ID is a 4-byte string which identifies the type of chunk.

The size field (a 32-bit value, encoded using big-endian byte order)
gives the size of the whole chunk, including the 8-byte header.

Usually an IFF-type file consists of one or more chunks.  The proposed
usage of the Chunk class defined here is to instantiate an instance at
the start of each chunk and read from the instance until it reaches
the end, after which a new instance can be instantiated.  At the end
of the file, creating a new instance will fail with an EOFError
exception.

Usage:
while True:
    try:
        chunk = Chunk(file)
    except EOFError:
        break
    chunktype = chunk.getname()
    while True:
        data = chunk.read(nbytes)
        if not data:
            pass
        # do something with data

The interface is file-like.  The implemented methods are:
read, close, seek, tell, isatty.
Extra methods are: skip() (called by close, skips to the end of the chunk),
getname() (returns the name (ID) of the chunk)

The __init__ method has one required argument, a file-like object
(including a chunk instance), and one optional argument, a flag which
specifies whether or not chunks are aligned on 2-byte boundaries.  The
default is 1, i.e. aligned.
"""

class Chunk:
    def __init__(self, file, align=True, bigendian=True, inclheader=False):
        import struct
        self.closed = False
        self.align = align      # whether to align to word (2-byte) boundaries
        if bigendian:
            strflag = '>'
        else:
            strflag = '<'
        self.file = file
        self.chunkname = file.read(4)
        if len(self.chunkname) < 4:
            raise EOFError
        try:
            self.chunksize = struct.unpack_from(strflag+'L', file.read(4))[0]
        except struct.error:
            raise EOFError
        if inclheader:
            self.chunksize = self.chunksize - 8 # subtract header
        self.size_read = 0
        try:
            self.offset = self.file.tell()
        except (AttributeError, OSError):
            self.seekable = False
        else:
            self.seekable = True

    def getname(self):
        """Return the name (ID) of the current chunk."""
        return self.chunkname

    def getsize(self):
        """Return the size of the current chunk."""
        return self.chunksize

    def close(self):
        if not self.closed:
            try:
                self.skip()
            finally:
                self.closed = True

    def isatty(self):
        if self.closed:
            raise ValueError("I/O operation on closed file")
        return False

    def seek(self, pos, whence=0):
        """Seek to specified position into the chunk.
        Default position is 0 (start of chunk).
        If the file is not seekable, this will result in an error.
        """

        if self.closed:
            raise ValueError("I/O operation on closed file")
        if not self.seekable:
            raise OSError("cannot seek")
        if whence == 1:
            pos = pos + self.size_read
        elif whence == 2:
            pos = pos + self.chunksize
        if pos < 0 or pos > self.chunksize:
            raise RuntimeError
        self.file.seek(self.offset + pos, 0)
        self.size_read = pos

    def tell(self):
        if self.closed:
            raise ValueError("I/O operation on closed file")
        return self.size_read

    def read(self, size=-1):
        """Read at most size bytes from the chunk.
        If size is omitted or negative, read until the end
        of the chunk.
        """

        if self.closed:
            raise ValueError("I/O operation on closed file")
        if self.size_read >= self.chunksize:
            return b''
        if size < 0:
            size = self.chunksize - self.size_read
        if size > self.chunksize - self.size_read:
            size = self.chunksize - self.size_read
        data = self.file.read(size)
        self.size_read = self.size_read + len(data)
        if self.size_read == self.chunksize and \
           self.align and \
           (self.chunksize & 1):
            dummy = self.file.read(1)
            self.size_read = self.size_read + len(dummy)
        return data

    def skip(self):
        """Skip the rest of the chunk.
        If you are not interested in the contents of the chunk,
        this method should be called so that the file points to
        the start of the next chunk.
        """

        if self.closed:
            raise ValueError("I/O operation on closed file")
        if self.seekable:
            try:
                n = self.chunksize - self.size_read
                # maybe fix alignment
                if self.align and (self.chunksize & 1):
                    n = n + 1
                self.file.seek(n, 1)
                self.size_read = self.size_read + n
                return
            except OSError:
                pass
        while self.size_read < self.chunksize:
            n = min(8192, self.chunksize - self.size_read)
            dummy = self.read(n)
            if not dummy:
                raise EOFError
__future__.py4841V
__phello__.foo.py64V
__pycache__-
_bootlocale.py1301V
_collections_abc.py26392V
_compat_pickle.py8749V
_compression.py5340V
_dummy_thread.py5118V
_markupbase.py14598V
_osx_support.py19138V
_pydecimal.py230228V
_pyio.py88097V
_sitebuiltins.py3115V
_strptime.py24747V
_sysconfigdata_dm_linux_x86_64-linux-gnu.py30191V
_sysconfigdata_m_linux_x86_64-linux-gnu.py30367V
_threading_local.py7214V
_weakrefset.py5705V
abc.py8727V
aifc.py32454V
antigravity.py477V
argparse.py90372V
ast.py12166V
asynchat.py11328V
asyncio-
asyncore.py20159V
base64.py20388V
bdb.py23556V
binhex.py13954V
bisect.py2595V
bz2.py12478V
cProfile.py5380V
calendar.py23213V
cgi.py37219V
cgitb.py12018V
chunk.py5425V
cmd.py14860V
code.py10614V
codecs.py36276V
codeop.py5994V
collections-
colorsys.py4064V
compileall.py12125V
concurrent-
config-3.6m-x86_64-linux-gnu-
configparser.py53592V
contextlib.py13162V
copy.py8815V
copyreg.py7007V
crypt.py1864V
csv.py16180V
ctypes-
curses-
datetime.py82034V
dbm-
decimal.py320V
difflib.py84377V
dis.py18132V
distutils-
doctest.py104391V
dummy_threading.py2815V
email-
encodings-
ensurepip-
enum.py33606V
filecmp.py9830V
fileinput.py14471V
fnmatch.py3166V
formatter.py15143V
fractions.py23639V
ftplib.py35617V
functools.py31346V
genericpath.py5028V
getopt.py7489V
getpass.py5994V
gettext.py21530V
glob.py5638V
gzip.py20334V
hashlib.py8799V
heapq.py22929V
hmac.py6381V
html-
http-
imaplib.py53464V
imghdr.py3795V
imp.py10669V
importlib-
inspect.py116958V
io.py3517V
ipaddress.py77818V
json-
keyword.py2219V
lib-dynload-
lib2to3-
linecache.py5312V
locale.py77300V
logging-
lzma.py12983V
macpath.py5971V
macurl2path.py2732V
mailbox.py78624V
mailcap.py9067V
mimetypes.py21042V
modulefinder.py23027V
multiprocessing-
netrc.py5684V
nntplib.py43078V
ntpath.py23094V
nturl2path.py2444V
numbers.py10243V
opcode.py5822V
operator.py10863V
optparse.py60371V
os.py37526V
pathlib.py46238V
pdb.py61320V
pickle.py55691V
pickletools.py91775V
pipes.py8916V
pkgutil.py21315V
platform.py47214V
plistlib.py32291V
poplib.py15087V
posixpath.py16324V
pprint.py20860V
profile.py22029V
pstats.py26564V
pty.py4763V
py_compile.py7181V
pyclbr.py13558V
pydoc.py103501V
pydoc_data-
queue.py8780V
quopri.py7262V
random.py27442V
re.py15552V
reprlib.py5336V
rlcompleter.py7097V
runpy.py11959V
sched.py6511V
secrets.py2038V
selectors.py19438V
shelve.py8515V
shlex.py12956V
shutil.py40829V
signal.py2123V
site-packages-
site.py21268V
smtpd.py34719V
smtplib.py44218V
sndhdr.py7088V
socket.py27443V
socketserver.py27010V
sqlite3-
sre_compile.py19338V
sre_constants.py6821V
sre_parse.py36536V
ssl.py44509V
stat.py5038V
statistics.py20673V
string.py11795V
stringprep.py12917V
struct.py257V
subprocess.py62339V
sunau.py18095V
symbol.py2119V
symtable.py7277V
sysconfig.py24876V
tabnanny.py11411V
tarfile.py111635V
telnetlib.py23136V
tempfile.py28066V
test-
textwrap.py19558V
this.py1003V
threading.py50136V
timeit.py13342V
token.py3075V
tokenize.py29496V
trace.py28733V
traceback.py23458V
tracemalloc.py16658V
tty.py879V
types.py8870V
typing.py80274V
unittest-
urllib-
uu.py6763V
uuid.py24020V
venv-
warnings.py18488V
wave.py17709V
weakref.py20466V
webbrowser.py22238V
wsgiref-
xdrlib.py5913V
xml-
xmlrpc-
zipapp.py7157V
zipfile.py79924V
MyMelon - Digital Marketing and Creative Agency in Delhi, India
Skip to content Skip to footer

MyMelon Home Page

Bored Of Old School Strategies?

Conventional strategies do no justice to complex modern problems. Bringing in kickass blueprints to escalate your exclusive ideas to the growth trajectory.

MyMelon Home Page (1)

Falling In Love With Your Problems

Your problems are our play! You get to decide which ‘solutions’ feel like an astounding fuck yes!

Discover pitch-perfect marketing strategies to deliver complex ideas into simplified solutions. 

Diversity in our problem solving approach makes us who we are!

You Do You

For us every client and their offerings are unique. We offer tailored and hot-off-the-press strategies to produce a unique brand identity. Listening, evolving, and promoting your articles of faith is what makes our work kickass and compelling too!

#
Award
Type
Project
01
Best Project
Art Business
Business Style
2017
02
Best Design
Creative Work
Best Designers
2018
03
Best Concept
New Strategy
Branding Concept
2019
04
Best Picture
Visualization
Small Figures
2020

Our Inspirations

Vivekanand

Arise, awake, and stop not until the goal is achieved

Dr APJ Abdul Kalam

Creativity is seeing the same thing but thinking differently

Christopher Columbus

By prevailing over all obstacles one may unfailingly arrive at his chosen goal.

JRD Tata

Uncommon thinkers reuse what common thinkers refuse.

Lead The Way With Your New Digital Partners

Waiting to get viral? Don’t worry we’ve got your back!

Leading your way through business acumen and business strategies tailored to your needs.

Handholding you since your first lightbulb moment to making a mark in the industry through unique formulas.  Bringing unexpected things to the table is in our DNA.

Producing Tailored Solutions

One solution for multiple solutions is hard to swallow. Creating tailored solutions for your unique problems

Setting Benchmarks

Doesn’t carving a path for others give the best kick ever?

Making A Difference

You can’t wait for a case study. You will be too late!

Blogs

Contact Us

We work hard and then succeed on purpose.

We are constantly looking for a needle in a haystack and connecting to get the deal to happen!

If you've loved our idea and want to take the road less traveled, reach out to us on …….

Before you take the sure-shots of success, let's take some shots of vodka!

    Polscy gracze coraz częściej wybierają kasyno bez weryfikacji przy wypłacie bez ukrytych opłat, aby cieszyć się szybkim dostępem do gier i przejrzystymi warunkami wypłaty wygranych. Tego typu platformy stawiają na uproszczoną rejestrację, nowoczesne metody płatności oraz jasne zasady dotyczące transakcji. Przed rozpoczęciem gry warto zapoznać się z opiniami innych użytkowników, aby ocenić jakość obsługi i niezawodność serwisu.

    Jeśli chcesz znaleźć rzetelne opinie oraz porównać najlepsze platformy, casino Revolut Pay może pomóc Ci podjąć świadomą decyzję. Znajdziesz tam recenzje użytkowników, szczegóły bonusów oraz informacje o wpłatach i wypłatach w kasynach akceptujących Revolut.

    People searching for gerçek canlı casino usually mean live-dealer roulette, blackjack, baccarat, or game-show tables streamed from a studio with a real dealer, rather than an RNG-only game. To assess authenticity, verify the operator’s licence directly with the regulator, check the named game provider and studio, look for clear rules and table limits, inspect withdrawal terms, and confirm that the service is legal in your jurisdiction; a foreign licence does not automatically make an operator legal in Türkiye.

    [canlı casino lisans rehberi](https://guvenilircanlicasinos.com/)[gerçek krupiyeli oyunlar](https://www.livecasinos.com/tr/) [guvenilircanlicasinos](https://guvenilircanlicasinos.com/)

    Many Dutch players now look for beste online casino iDEAL to benefit from secure iDEAL deposits, low minimum stakes, and quick withdrawals. These casinos integrate trusted Dutch payment infrastructure with streamlined cashout systems, ideal for users who value speed, simplicity, and transparent transactions. By consulting authentic player reviews, gamblers can identify sites that consistently deliver rapid payouts and a seamless gaming experience.

    Gli online casinos with bancoposta sono principalmente operatori che accettano la carta Visa o Mastercard collegata al conto BancoPosta per depositi e, in alcuni casi, prelievi. Tra i nomi più citati in Italia figurano 888casino, SNAI, LeoVegas, Planetwin365, Gioco Digitale, Sisal e StarCasinò, con depositi minimi spesso tra 10€ e 20€ e limiti massimi che possono arrivare a diverse migliaia di euro. Per utilizzare la carta, di solito basta selezionare Visa o Mastercard alla cassa, inserire i dati della carta BancoPosta e completare la verifica 3D Secure; i prelievi possono tornare sulla stessa carta o sul conto tramite bonifico, con tempi tipici da 24 ore a 3–5 giorni lavorativi.

    Gracze poszukujący sprawdzonych platform często wybierają kasyno niemcy, które oferuje przejrzyste zasady wypłat i bezpieczne metody płatności. Przed rejestracją warto porównać limity transakcji, czas realizacji przelewów oraz dostępne opcje wpłat, aby uniknąć niepotrzebnych opóźnień. Opinie innych użytkowników mogą pomóc ocenić rzetelność obsługi, jakość gier i ogólny komfort korzystania z platformy.

    Oferty określane jako zagraniczne kasyna bonus bez depozytu mogą obejmować darmowe spiny lub niewielkie środki promocyjne przyznawane po rejestracji i weryfikacji konta. Przed skorzystaniem z promocji należy dokładnie sprawdzić wymagania obrotu, maksymalną wypłatę, czas ważności bonusu oraz ograniczenia dla użytkowników z Polski. Zagraniczna licencja nie legalizuje automatycznie działalności hazardowej w Polsce, dlatego warto zweryfikować operatora w oficjalnych źródłach i grać odpowiedzialnie .