             Scalar4 angmom = tex1Dfetch(rigid_data_angmom_tex, idx_body);
             Scalar4 force = tex1Dfetch(rigid_data_force_tex, idx_body);
             Scalar4 torque = tex1Dfetch(rigid_data_torque_tex, idx_body);
+			#elif defined ENABLE_TEXTURES
+			Scalar4 vel = fetch_double4(rigid_data_vel_tex, idx_body);
+			Scalar4 angmom = fetch_double4(rigid_data_angmom_tex, idx_body);
+			Scalar4 force = fetch_double4(rigid_data_force_tex, idx_body);
+			Scalar4 torque = fetch_double4(rigid_data_torque_tex, idx_body);
 			#else
 			Scalar4 vel = rdata_vel[idx_body];
 			Scalar4 angmom = rdata_angmom[idx_body];

texture<Scalar4, 1, cudaReadModeElementType> rigid_data_force_tex;
//! The texture for reading the rigid data torque array
texture<Scalar4, 1, cudaReadModeElementType> rigid_data_torque_tex;

//! The texture for reading the net force array
texture<Scalar4, 1, cudaReadModeElementType> net_force_tex;
#endif

//! Shared memory used in reducing sums

				#ifdef SINGLE_PRECISION
                torque = tex1Dfetch(rigid_data_torque_tex, idx_body);
                angvel = tex1Dfetch(rigid_data_angvel_tex, idx_body);
				#elif defined ENABLE_TEXTURES
				torque = fetch_double4(rigid_data_torque_tex, idx_body);
				angvel = fetch_double4(rigid_data_angvel_tex, idx_body);
				#else
				torque = rdata_torque[idx_body];
				angvel = rdata_angvel[idx_body];
