本文整理汇总了C#中DetailLevel类的典型用法代码示例。如果您正苦于以下问题:C# DetailLevel类的具体用法?C# DetailLevel怎么用?C# DetailLevel使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
DetailLevel类属于命名空间,在下文中一共展示了DetailLevel类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ListWorkItems
/// <summary>
/// Returns a list of WorkItems
/// </summary>
/// <returns></returns>
public IEnumerable<ICloudWorkItem> ListWorkItems(DetailLevel detailLevel = null)
{
using (IWorkItemManager wiManager = this.Client.OpenWorkItemManager())
{
return wiManager.ListWorkItems(detailLevel);
}
}
示例2: YumlModelDiagramProvider
/// <summary>
/// Initializes a new instance of the <see cref="YumlModelDiagramProvider" /> class.
/// </summary>
/// <param name="models">The models.</param>
/// <param name="detailLevels">The detail levels.</param>
public YumlModelDiagramProvider(IEnumerable<Type> models, DetailLevel[] detailLevels)
{
this.Models = models;
// Configure generator
this.yumlFactory = this.GetYumlFactory(this.Models);
// Get image path
this.Image = this.yumlFactory.GenerateClassDiagramUri(detailLevels);
}
示例3: GetWorldMesh
public SimpleMesh GetWorldMesh(DetailLevel lod, SimulationObject parent)
{
int i = (int)lod;
if (WorldTransformedMeshes[i] != null)
{
return WorldTransformedMeshes[i];
}
else
{
// Get the untransformed mesh
SimpleMesh mesh = GetMesh(lod);
// Copy to our new mesh
SimpleMesh transformedMesh = new SimpleMesh();
transformedMesh.Indices = new List<ushort>(mesh.Indices);
transformedMesh.Path.Open = mesh.Path.Open;
transformedMesh.Path.Points = new List<PathPoint>(mesh.Path.Points);
transformedMesh.Prim = mesh.Prim;
transformedMesh.Profile.Concave = mesh.Profile.Concave;
transformedMesh.Profile.Faces = new List<ProfileFace>(mesh.Profile.Faces);
transformedMesh.Profile.MaxX = mesh.Profile.MaxX;
transformedMesh.Profile.MinX = mesh.Profile.MinX;
transformedMesh.Profile.Open = mesh.Profile.Open;
transformedMesh.Profile.Positions = new List<Vector3>(mesh.Profile.Positions);
transformedMesh.Profile.TotalOutsidePoints = mesh.Profile.TotalOutsidePoints;
transformedMesh.Vertices = new List<Vertex>(mesh.Vertices);
// Construct a matrix to transform to world space
Matrix4 transform = Matrix4.Identity;
if (parent != null)
{
// Apply parent rotation and translation first
transform *= Matrix4.CreateFromQuaternion(parent.Prim.Rotation);
transform *= Matrix4.CreateTranslation(parent.Prim.Position);
}
transform *= Matrix4.CreateScale(this.Prim.Scale);
transform *= Matrix4.CreateFromQuaternion(this.Prim.Rotation);
transform *= Matrix4.CreateTranslation(this.Prim.Position);
// Transform the mesh
for (int j = 0; j < transformedMesh.Vertices.Count; j++)
{
Vertex vertex = transformedMesh.Vertices[j];
vertex.Position *= transform;
transformedMesh.Vertices[j] = vertex;
}
WorldTransformedMeshes[i] = transformedMesh;
return transformedMesh;
}
}
示例4: GetUserDetails
/// <summary>
/// Get the user details
/// </summary>
/// <param name="userId">the user id</param>
/// <param name="detailLevel">the detail level</param>
/// <returns>the async state</returns>
public IAsyncResult GetUserDetails(int userId, DetailLevel detailLevel)
{
if (!ServiceHelper.TestCallPrerequisites(this, this.GetUserDetailsCompleted, this.etsyContext))
{
return null;
}
UriBuilder uriBuilder = UriBuilder.Start(this.etsyContext, "users", userId)
.DetailLevel(detailLevel);
return ServiceHelper.GenerateRequest(this, uriBuilder.Result(), this.GetUserDetailsCompleted);
}
示例5: GetUserDetails
/// <summary>
/// Get the user details
/// </summary>
/// <param name="userId">the user id</param>
/// <param name="detailLevel">the detail level</param>
/// <returns>the async state</returns>
public IAsyncResult GetUserDetails(int userId, DetailLevel detailLevel)
{
if (!RequestHelper.TestCallPrerequisites(this, this.GetUserDetailsCompleted, this.etsyContext))
{
return null;
}
EtsyUriBuilder etsyUriBuilder = EtsyUriBuilder.Start(this.etsyContext, "users", userId)
.DetailLevel(detailLevel);
return this.dataRetriever.StartRetrieve(etsyUriBuilder.Result(), this.GetUserDetailsCompleted);
}
示例6: GetFeaturedDetails
/// <summary>
/// Get the expanded details on featured listings of a shop, ordered by highest ranked featured item.
/// </summary>
/// <param name="userName">the user name</param>
/// <param name="detailLevel">the level of detail</param>
/// <returns>the async state</returns>
public IAsyncResult GetFeaturedDetails(string userName, DetailLevel detailLevel)
{
if (!ServiceHelper.TestCallPrerequisites(this, this.GetFeaturedDetailsCompleted, this.etsyContext))
{
return null;
}
UriBuilder uriBuilder = UriBuilder.Start(this.etsyContext, "shops/", userName)
.Append("/listings/featured")
.DetailLevel(detailLevel);
return ServiceHelper.GenerateRequest(this, uriBuilder.Result(), this.GetFeaturedDetailsCompleted);
}
示例7: GetUsersByName
/// <summary>
/// Query for users by name
/// </summary>
/// <param name="searchName">the name to search for</param>
/// <param name="offset">the searh results offset</param>
/// <param name="limit">the search limit</param>
/// <param name="detailLevel">the level of detail</param>
/// <returns>the async state</returns>
public IAsyncResult GetUsersByName(string searchName, int offset, int limit, DetailLevel detailLevel)
{
if (!ServiceHelper.TestCallPrerequisites(this, this.GetUsersByNameCompleted, this.etsyContext))
{
return null;
}
UriBuilder uriBuilder = UriBuilder.Start(this.etsyContext, "users/keywords", searchName)
.OffsetLimit(offset, limit)
.DetailLevel(detailLevel);
return ServiceHelper.GenerateRequest(this, uriBuilder.Result(), this.GetUsersByNameCompleted);
}
示例8: GenerateFacetedMesh
public FacetedMesh GenerateFacetedMesh(Primitive prim, DetailLevel lod)
{
Path path = GeneratePath();
Profile profile = GenerateProfile();
FacetedMesh mesh = new FacetedMesh();
mesh.Prim = prim;
mesh.Path = path;
mesh.Profile = profile;
mesh.Faces = GenerateFaces(prim.Textures);
return mesh;
}
示例9: GetFavorersOfListing
/// <summary>
/// Get all the users who call this listing a favorite.
/// </summary>
/// <param name="listingId">the listing's numeric ID</param>
/// <param name="offset">To page through large result sets, set offset to a multiple of limit</param>
/// <param name="limit">Specify the number of results to return</param>
/// <param name="detailLevel">Control how much information to return</param>
/// <returns>The Async state of the request</returns>
public IAsyncResult GetFavorersOfListing(int listingId, int offset, int limit, DetailLevel detailLevel)
{
if (!ServiceHelper.TestCallPrerequisites(this, this.GetFavorersOfListingCompleted, this.etsyContext))
{
return null;
}
UriBuilder uriBuilder = UriBuilder.Start(this.etsyContext, "listings", listingId)
.Append("/favorers")
.OffsetLimit(offset, limit)
.DetailLevel(detailLevel);
return ServiceHelper.GenerateRequest(this, uriBuilder.Result(), this.GetFavorersOfListingCompleted);
}
示例10: GenerateSimpleMesh
public SimpleMesh GenerateSimpleMesh(Primitive prim, DetailLevel lod)
{
Path path = GeneratePath();
Profile profile = GenerateProfile();
SimpleMesh mesh = new SimpleMesh();
mesh.Prim = prim;
mesh.Path = path;
mesh.Profile = profile;
mesh.Vertices = GenerateVertices();
mesh.Indices = GenerateIndices();
return mesh;
}
示例11: GetMesh
public SimpleMesh GetMesh(DetailLevel lod)
{
int i = (int)lod;
if (Meshes[i] != null)
{
return Meshes[i];
}
else
{
Primitive prim = (Primitive)Prim;
SimpleMesh mesh = Server.Mesher.GenerateSimpleMesh(prim, lod);
Meshes[i] = mesh;
return mesh;
}
}
示例12: GenerateSimpleMesh
public SimpleMesh GenerateSimpleMesh(Primitive prim, DetailLevel lod)
{
float detail = DETAIL_LEVELS[(int)lod];
Path path = GeneratePath(prim.Data, detail);
Profile profile = GenerateProfile(prim.Data, path, detail);
SimpleMesh mesh = new SimpleMesh();
mesh.Prim = prim;
mesh.Path = path;
mesh.Profile = profile;
mesh.Vertices = GenerateVertices(prim.Data, detail, path, profile);
mesh.Indices = GenerateIndices(prim.Data, path, profile);
return mesh;
}
示例13: GenerateFacetedMesh
public FacetedMesh GenerateFacetedMesh(Primitive prim, DetailLevel lod)
{
float detail = DETAIL_LEVELS[(int)lod];
Path path = GeneratePath(prim.Data, detail);
Profile profile = GenerateProfile(prim.Data, path, detail);
List<Vertex> vertices = GenerateVertices(prim.Data, detail, path, profile);
FacetedMesh mesh = new FacetedMesh();
mesh.Prim = prim;
mesh.Path = path;
mesh.Profile = profile;
mesh.Faces = CreateVolumeFaces(prim, path, profile, vertices);
return mesh;
}
示例14: GetGiftGuideListings
/// <summary>
/// Get the listings in a gift guide.
/// </summary>
/// <param name="guideId">Specify the numeric ID of a Gift Guide </param>
/// <param name="offset">To page through large result sets, set offset to a multiple of limit</param>
/// <param name="limit">Specify the number of results to return</param>
/// <param name="detailLevel">Control how much information to return</param>
/// <returns>The Async state of the request</returns>
public IAsyncResult GetGiftGuideListings(int guideId, int offset, int limit, DetailLevel detailLevel)
{
if (!RequestHelper.TestCallPrerequisites(this, this.GetGiftGuideListingsCompleted, this.etsyContext))
{
return null;
}
if (!RequestHelper.TestOffsetLimit(this, this.GetGiftGuideListingsCompleted, offset, limit))
{
return null;
}
EtsyUriBuilder etsyUriBuilder = EtsyUriBuilder.Start(this.etsyContext, "gift-guides", guideId)
.Append("/listings")
.OffsetLimit(offset, limit)
.DetailLevel(detailLevel);
return this.dataRetriever.StartRetrieve(etsyUriBuilder.Result(), this.GetGiftGuideListingsCompleted);
}
示例15: GenerateSimpleSculptMesh
public SimpleMesh GenerateSimpleSculptMesh(Primitive prim, Bitmap sculptTexture, DetailLevel lod)
{
FacetedMesh facetedMesh = GenerateFacetedSculptMesh(prim, sculptTexture, lod);
if (facetedMesh != null && facetedMesh.Faces.Count == 1)
{
Face face = facetedMesh.Faces[0];
SimpleMesh mesh = new SimpleMesh();
mesh.Indices = face.Indices;
mesh.Vertices = face.Vertices;
mesh.Path = facetedMesh.Path;
mesh.Profile = facetedMesh.Profile;
mesh.Prim = facetedMesh.Prim;
return mesh;
}
return null;
}