Esempio n. 1
0
    def mdo(frame, command, _self=cmd):
        """
DESCRIPTION

    "mdo" defines (or redefines) the command-line operations
    associated with a particular movie frame.  These "generalized
    movie commands" will be executed every time the numbered frame is
    played.

USAGE

    mdo frame: command

PYMOL API

    cmd.mdo( int frame, string command )

EXAMPLE

    // Creates a single frame movie involving a rotation about X and Y

    load test.pdb
    mset 1
    mdo 1, turn x,5; turn y,5;
    mplay

NOTES

 These commands are usually created
    by a PyMOL utility program (such as util.mrock).  Command can
    actually contain several commands separated by semicolons ';'
    
    The "mset" command must first be used to define the movie before
    "mdo" statements will have any effect.  Redefinition of the movie
    clears any existing mdo statements.

SEE ALSO

    mset, mplay, mstop
        """
        r = DEFAULT_ERROR
        try:
            _self.lock(_self)
            r = _cmd.mdo(_self._COb, int(frame) - 1, str(command), 0)
        finally:
            _self.unlock(r, _self)
        if _self._raising(r, _self):
            raise pymol.CmdException
        return r
Esempio n. 2
0
    def mdo(frame, command, _self=cmd):
        '''
DESCRIPTION

    "mdo" defines (or redefines) the command-line operations
    associated with a particular movie frame.  These "generalized
    movie commands" will be executed every time the numbered frame is
    played.

USAGE

    mdo frame: command

PYMOL API

    cmd.mdo( int frame, string command )

EXAMPLE

    // Creates a single frame movie involving a rotation about X and Y

    load test.pdb
    mset 1
    mdo 1, turn x,5; turn y,5;
    mplay

NOTES

 These commands are usually created
    by a PyMOL utility program (such as util.mrock).  Command can
    actually contain several commands separated by semicolons ';'
    
    The "mset" command must first be used to define the movie before
    "mdo" statements will have any effect.  Redefinition of the movie
    clears any existing mdo statements.

SEE ALSO

    mset, mplay, mstop
        '''
        r = DEFAULT_ERROR
        try:
            _self.lock(_self)
            r = _cmd.mdo(_self._COb, int(frame) - 1, str(command), 0)
        finally:
            _self.unlock(r, _self)
        if _self._raising(r, _self): raise pymol.CmdException
        return r
Esempio n. 3
0
    def mappend(frame, command, _self=cmd):
        """
DESCRIPTION

    "mappend" associates additional command line operations with a
    particular movie frame.  These "generalized movie commands" will
    be executed every time the numbered frame is played.
    
USAGE

    mappend frame: command

ARGUMENTS

    frame = integer: the frame to modify

    command = literal command-line text
    
EXAMPLE

    mappend 1: hide everything; show sticks
    mappend 60: hide sticks; show spheres
    mappend 120: hide spheres; show surface
    
NOTES

    The "mset" command must first be used to define the movie before
    "mdo" statements will have any effect.  Redefinition of the movie
    clears any existing movie commands specified with mdo or mappend.

SEE ALSO

    mset, madd, mdo, mplay, mstop
        """
        r = DEFAULT_ERROR
        try:
            _self.lock(_self)
            r = _cmd.mdo(_self._COb, int(frame) - 1, str(";" + command), 1)
        finally:
            _self.unlock(r, _self)
        if _self._raising(r, _self):
            raise pymol.CmdException
        return r
Esempio n. 4
0
    def mappend(frame, command, _self=cmd):
        '''
DESCRIPTION

    "mappend" associates additional command line operations with a
    particular movie frame.  These "generalized movie commands" will
    be executed every time the numbered frame is played.
    
USAGE

    mappend frame: command

ARGUMENTS

    frame = integer: the frame to modify

    command = literal command-line text
    
EXAMPLE

    mappend 1: hide everything; show sticks
    mappend 60: hide sticks; show spheres
    mappend 120: hide spheres; show surface
    
NOTES

    The "mset" command must first be used to define the movie before
    "mdo" statements will have any effect.  Redefinition of the movie
    clears any existing movie commands specified with mdo or mappend.

SEE ALSO

    mset, madd, mdo, mplay, mstop
        '''
        r = DEFAULT_ERROR
        try:
            _self.lock(_self)
            r = _cmd.mdo(_self._COb, int(frame) - 1, str(";" + command), 1)
        finally:
            _self.unlock(r, _self)
        if _self._raising(r, _self): raise pymol.CmdException
        return r