Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
1
Question by Eric 1 · Apr 09, 2010 at 11:10 PM · webplayerwebrequest

Will .Net WebRequest be available in Unity 3.0 web player?

We are testing using Unity for some online 3D content. We tried to use the WebRequest interface available in .Net but learned it's not available in .Net runtime in the Unity web player.

Since we need stream based access to the http reponse data (which the Unity WWW doesn't provide), we've implemented our own basic HTTP client code with .Net TcpClient and .Net Sockets.

Will the WebRequest (and WebProxy) interfaces be available for use in the Unity Web Player in version 3.0? In the past, it was mentioned it might be availble in a Unity version 2.7 (but I don't think that is going to exist).

cheers, Eric

Software Architect www.mixamo.com

Comment
Add comment · Show 1
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image KvanteTore · Apr 15, 2010 at 08:54 PM 0
Share

I second that! It would be awesome to have more feature rich http-class than UnityEngine.WWW.

2 Replies

· Add your reply
  • Sort: 
avatar image
1

Answer by Lucas Meijer 1 · May 22, 2010 at 10:24 PM

There is no final decision on this yet. When you say HTTP response data, I assume that you mean HTTP response header data. I have added that as a feature to the builtin WWW class. Other than the hTTP response headers, is there anything else that WebConnection/WebRequest would offer you that our builtin WWW class does not?

Comment
Add comment · Show 4 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Tray · May 23, 2010 at 08:05 AM 0
Share

Several 3rd party .NET assemblies, some are open source, have built in communication calls with server pages going over HTTP. They generally use web request in an async manner. Not having this class/object available in the web player leaves this sort of integration a mess, and really the only option is to hack up the open source with a custom version that somehow uses www, or try to build my own version or sub set of open source functionality for some of the things I'd like to do. If this class is available, like it is in stand along version, it works great. I like www, but please please add

avatar image Eric 1 · May 24, 2010 at 04:58 PM 0
Share

Lucas, thanks for the follow up. Just to clarify my request...when I say "stream based access to the http reponse data" what I mean is literally have access to a System.IO.Stream instance which allows me to read HTTP response body byte by byte as it becomes available from the server (separate from the HTTP response headers). This is compared to the interface that WWW provides which is a byte array that is available ONLY after the response has been completely received by the client. (DUE TO SPACE CONSTRAINTS...CONTINUED BELOW...)

avatar image Eric 1 · May 24, 2010 at 05:03 PM 0
Share

(CONT FRO$$anonymous$$ ABOVE) Providing access to the .Net/$$anonymous$$ono WebRequest would provide that functionality without having to complicate the existing WWW class API. Similiary, since we are experiencing severe stability issues using $$anonymous$$ono Sockets and Threads directly with our own HTTP client code as a work around to not having access to WebRequest, we are really hoping for an "offical" solution that doesn't crash $$anonymous$$ono/Unity. We have multiple case numbers about the crashes we are experiencing. With all that said, having access to HTTP headers in the WWW class is also a good idea. :)

avatar image burnumd · Oct 27, 2010 at 11:01 PM 0
Share

WWW also doesn't support proxy traversal in Standalone builds, which is why we resorted to HttpWebRequest in 2.6. 3.0 appears to break on WebRequest.Create without even handling the exception.

avatar image
0

Answer by qJake · Apr 10, 2010 at 03:06 AM

I'm not entirely sure if this will work in your case, but have you tried using System.Net.WebClient? I remember hearing from others that that is available in the Web player, but I don't know if it can suit your needs or not.

Comment
Add comment · Show 2 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image KvanteTore · Apr 15, 2010 at 08:52 PM 0
Share

That would probably be me, but I have since learned that although the HttpWebRequest is available in the editor, it is not available in the webplayer. :(

avatar image Eric 1 · May 06, 2010 at 10:05 PM 0
Share

Yeah, as your discovered, WebClient is based on WebRequest which is not available in the web player.

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

No one has followed this question yet.

Related Questions

How do I have multiple UnityWebRequests in one coroutine? 1 Answer

What is the equivalent of unityWebRequest.downloadHandler.text when using WWW? 0 Answers

Why can't I build Web Player in Unity while I have no problems with building standalone versions? 2 Answers

Draw on Image 0 Answers

Loading data from a different game 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges