Lines Matching refs:view_src
525 Py_buffer view_dest, view_src; in PyObject_CopyData() local
539 if (PyObject_GetBuffer(src, &view_src, PyBUF_FULL_RO) != 0) { in PyObject_CopyData()
544 if (view_dest.len < view_src.len) { in PyObject_CopyData()
548 PyBuffer_Release(&view_src); in PyObject_CopyData()
553 PyBuffer_IsContiguous(&view_src, 'C')) || in PyObject_CopyData()
555 PyBuffer_IsContiguous(&view_src, 'F'))) { in PyObject_CopyData()
557 memcpy(view_dest.buf, view_src.buf, view_src.len); in PyObject_CopyData()
559 PyBuffer_Release(&view_src); in PyObject_CopyData()
566 indices = (Py_ssize_t *)PyMem_Malloc(sizeof(Py_ssize_t)*view_src.ndim); in PyObject_CopyData()
570 PyBuffer_Release(&view_src); in PyObject_CopyData()
573 for (k=0; k<view_src.ndim;k++) { in PyObject_CopyData()
577 for (k=0; k<view_src.ndim; k++) { in PyObject_CopyData()
579 elements *= view_src.shape[k]; in PyObject_CopyData()
582 _Py_add_one_to_index_C(view_src.ndim, indices, view_src.shape); in PyObject_CopyData()
584 sptr = PyBuffer_GetPointer(&view_src, indices); in PyObject_CopyData()
585 memcpy(dptr, sptr, view_src.itemsize); in PyObject_CopyData()
589 PyBuffer_Release(&view_src); in PyObject_CopyData()